mirror of
https://github.com/enso-org/enso.git
synced 2024-12-18 14:01:37 +03:00
a7c2e7590a
- Closes https://github.com/enso-org/cloud-v2/issues/617 - Trash category - Do not open "confirm delete" modal when on remote (cloud) backend - Permanent deletion has been superseded by the trash category - Save current category to `localStorage` - Also implements "Recent" category. Differences to Home category: - Hides sort indicators - Disables sorting Other fixes: - Allow overriding cloud environment through environment variable - Prevent triggering rename on click when multiple items are selected - Remove "move to trash" context menu option when user is not owner # Important Notes - This registers the "Ctrl + R" (Cmd + R) shortcut for restoring an item from trash. This is the same shortcut used for renaming, however I think it is fine because items in trash cannot be renamed. (As usual though, this is very simple to remove/change so it's not a big deal to remove/change it.) - The "Recent" category lacks backend support - so it falls back to the default category, as the deserialization of unknown values falls back to the default category.
20 lines
435 B
Plaintext
20 lines
435 B
Plaintext
{
|
|
"React Component": {
|
|
"prefix": ["$c", "component"],
|
|
"body": [
|
|
"/** Props for a {@link $1}. */",
|
|
"export interface $1Props {",
|
|
"}",
|
|
"",
|
|
"/** $2 */",
|
|
"export default function $1(props: $1Props) {",
|
|
" return <div>$3</div>",
|
|
"}"
|
|
]
|
|
},
|
|
"useState": {
|
|
"prefix": ["$s", "usestate"],
|
|
"body": ["const [$1, set${1/(.*)/${1:/pascalcase}/}] = React.useState($2)"]
|
|
}
|
|
}
|