Import the utility function:
import rovingTabindex from './rovingTabindex';Init the function by bassing the required parameter:
| # Copy and paste it inside your terminal and press enter. | |
| # You may need to run this twice. | |
| defaults write com.apple.dock persistent-apps -array-add '{"tile-type"="spacer-tile";}'; killall Dock |
| body { | |
| margin: 0; | |
| } | |
| .FlexGrid { | |
| --gap: 12px; | |
| display: inline-flex; | |
| flex-wrap: wrap; | |
| margin: calc(-1 * var(--gap)) 0 0 calc(-1 * var(--gap)); |
| /* trigger is the prop that accepts a ReactNode */ | |
| const addAttr = useMemo(() => { | |
| const InputReactObject = Children.only(trigger); | |
| const clonedChild = cloneElement(inputReactObject, { | |
| className: 'input-element test', | |
| 'data-attr': 'lorem' | |
| }); | |
| return <InputReactObject />; |
| git checkout --orphan new-framework | |
| # completely rewrite your application in new framework | |
| git merge --strategy=ours --allow-unrelated-histories master | |
| git commit-tree -p HEAD^2 -p HEAD^1 -m "Merge branch 'new-framework'" "HEAD^{tree}" | |
| git reset --hard $OUTPUT_FROM_PREVIOUS_COMMAND | |
| git checkout master | |
| git merge --ff-only new-framework |
| /* | |
| * Make the element bleed on both side, | |
| * covering the whole viewport width. | |
| */ | |
| .FullBleed { | |
| margin-left: calc(50% - 50vw); | |
| width: 100vw; | |
| } |
| <!-- | |
| Put this file in ~/Library/LaunchAgents/com.example.KeyRemapping.plist to | |
| automatically remap your keys when macOS starts. | |
| See https://developer.apple.com/library/archive/technotes/tn2450/_index.html for | |
| the key "usage IDs". Take the usage ID and add 0x700000000 to it before putting it | |
| into a source or destination (HIDKeyboardModifierMappingSrc and | |
| HIDKeyboardModifierMappingDst respectively). | |
| --> | |
| <?xml version="1.0" encoding="UTF-8"?> | |
| <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> |
| # place this at the end | |
| # •••••••••••••••••••••••••••••••••••••••• | |
| _enter_dir() { | |
| local git_root | |
| git_root=$(git rev-parse --show-toplevel 2>/dev/null) | |
| if [[ "$git_root" == "$PREV_PWD" ]]; then | |
| return | |
| elif [[ -n "$git_root" && -f "$git_root/.nvmrc" ]]; then |
| /** | |
| * | |
| * Conversion Table (base 16px) | |
| * 30em → 480px | |
| * 48em → 768px | |
| * 60em → 960px | |
| * 80em → 1280px | |
| * 100em → 1600px | |
| * | |
| */ |
| $i: 5; | |
| $halfstar-style: url(#half-star) currentColor; | |
| $dimmed-star-opacity: 0.3; | |
| .ReviewIndicator { | |
| display: inline-flex; | |
| /** | |
| * Set consecutive icons spacing | |
| */ |