This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import "./styles.css"; | |
| import { Person } from "./types"; | |
| import { Listbox } from "./listbox/listbox"; | |
| import { useForm } from "react-hook-form"; | |
| const people: Person[] = [ | |
| { id: 1, name: "Durward Reynolds", unavailable: false }, | |
| { id: 2, name: "Kenton Towne", unavailable: false }, | |
| { id: 3, name: "Therese Wunsch", unavailable: false }, | |
| { id: 4, name: "Benedict Kessler", unavailable: true }, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| const input = require('./spec3.json') | |
| function titleCase(snake) { | |
| return snake.replace(/(^|_)([a-z])/g, (s) => s.replace('_', '').toUpperCase()) | |
| } | |
| function isPrimitive(schema) { | |
| switch (schema.type) { | |
| case 'boolean': | |
| case 'number': |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| class Frame extends Component { | |
| componentDidMount() { | |
| this.iframeHead = this.node.contentDocument.head | |
| this.iframeRoot = this.node.contentDocument.body | |
| this.forceUpdate() | |
| } | |
| render() { | |
| const { children, head, ...rest } = this.props | |
| return ( |