@vev/silke 1.0.10 → 1.0.12
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +9 -0
- package/dist/chunk-4MB64AQL.js +22 -0
- package/dist/chunk-4MB64AQL.js.LEGAL.txt +8 -0
- package/dist/chunk-4MB64AQL.js.map +7 -0
- package/dist/index.js +9 -25
- package/dist/index.js.LEGAL.txt +6 -9
- package/dist/index.js.map +4 -4
- package/dist/silke-code-editor-HZRG3D6C.js +23 -0
- package/dist/silke-code-editor-HZRG3D6C.js.map +7 -0
- package/dist/styles.css +4338 -2599
- package/esbuild.config.mjs +2 -1
- package/jest.config.js +2 -1
- package/package.json +12 -8
- package/src/_variables.scss +121 -1
- package/src/components/index.ts +6 -0
- package/src/components/silke-autocomplete-field/autocomplete-item.tsx +15 -13
- package/src/components/silke-autocomplete-field/autocomplete-tags.tsx +14 -7
- package/src/components/silke-autocomplete-field/silke-autocomplete-field.mdx +31 -4
- package/src/components/silke-autocomplete-field/silke-autocomplete-field.scss +8 -6
- package/src/components/silke-autocomplete-field/silke-autocomplete-field.tsx +64 -23
- package/src/components/silke-box/silke-box.scss +21 -47
- package/src/components/silke-box/silke-box.tsx +23 -31
- package/src/components/silke-breadcrumbs/silke-breadcrumb.scss +3 -3
- package/src/components/silke-button/index.ts +3 -1
- package/src/components/silke-button/silke-big-button.scss +38 -0
- package/src/components/silke-button/silke-big-button.tsx +49 -0
- package/src/components/silke-button/silke-button-set.tsx +15 -3
- package/src/components/silke-button/silke-button.mdx +41 -19
- package/src/components/silke-button/silke-button.scss +97 -90
- package/src/components/silke-button/silke-button.tsx +20 -5
- package/src/components/silke-button/silke-file-select-button.tsx +86 -0
- package/src/components/silke-card/silke-card-grid.tsx +9 -9
- package/src/components/silke-card/silke-card.mdx +23 -9
- package/src/components/silke-card/silke-card.scss +92 -39
- package/src/components/silke-card/silke-card.tsx +50 -27
- package/src/components/silke-checkbox/silke-checkbox.scss +39 -17
- package/src/components/silke-checkbox/silke-checkbox.tsx +4 -1
- package/src/components/silke-code-editor/index.tsx +12 -0
- package/src/components/silke-code-editor/silke-code-editor.mdx +97 -0
- package/src/components/silke-code-editor/silke-code-editor.tsx +52 -0
- package/src/components/silke-code-snippet/silke-code-snippet.scss +2 -10
- package/src/components/silke-code-snippet/silke-code-snippet.tsx +10 -3
- package/src/components/silke-color-palettes/silke-color-palette.tsx +11 -2
- package/src/components/silke-color-picker/color-picker.scss +10 -6
- package/src/components/silke-color-picker/silke-color-info.tsx +14 -4
- package/src/components/silke-color-picker/silke-color-picker-button.tsx +4 -3
- package/src/components/silke-color-picker/silke-color-picker.tsx +4 -2
- package/src/components/silke-color-picker/silke-opacity-slider.tsx +11 -12
- package/src/components/silke-color-swatches/silke-color-swatch-button.tsx +10 -4
- package/src/components/silke-color-swatches/silke-swatches.tsx +2 -2
- package/src/components/silke-content-column/index.ts +1 -0
- package/src/components/silke-content-column/silke-content-column.mdx +7 -0
- package/src/components/silke-content-column/silke-content-column.scss +39 -0
- package/src/components/silke-content-column/silke-content-column.tsx +14 -0
- package/src/components/silke-context-menu/silke-context-menu-item.tsx +9 -4
- package/src/components/silke-context-menu/silke-context-menu.mdx +16 -12
- package/src/components/silke-context-menu/silke-context-menu.scss +16 -0
- package/src/components/silke-context-menu/silke-context-menu.tsx +62 -39
- package/src/components/silke-css-number-field/silke-css-context.tsx +1 -0
- package/src/components/silke-css-number-field/silke-css-number-field.scss +18 -3
- package/src/components/silke-css-number-field/silke-css-number-field.tsx +32 -13
- package/src/components/silke-css-number-field/utils.ts +2 -0
- package/src/components/silke-divider/silke-divider.scss +4 -2
- package/src/components/silke-drawer/silke-drawer.scss +3 -3
- package/src/components/silke-drawer/silke-drawer.tsx +3 -3
- package/src/components/silke-form/silke-form.tsx +1 -9
- package/src/components/silke-form-schema/fields/array-field-inline.tsx +2 -3
- package/src/components/silke-form-schema/fields/array-field-modal.tsx +1 -1
- package/src/components/silke-form-schema/fields/array-field.tsx +2 -2
- package/src/components/silke-form-schema/fields/event-field.tsx +120 -0
- package/src/components/silke-form-schema/fields/icon-field.tsx +1 -1
- package/src/components/silke-form-schema/fields/image-field.tsx +1 -1
- package/src/components/silke-form-schema/fields/link-field.tsx +8 -1
- package/src/components/silke-form-schema/fields/number-field.tsx +24 -8
- package/src/components/silke-form-schema/fields/object-field.tsx +1 -1
- package/src/components/silke-form-schema/fields/select-field.tsx +9 -2
- package/src/components/silke-form-schema/fields/styles.scss +2 -2
- package/src/components/silke-form-schema/fields/toggle-field.tsx +14 -13
- package/src/components/silke-form-schema/fields/upload-field.tsx +37 -0
- package/src/components/silke-form-schema/fields/utils/generate-image.ts +3 -4
- package/src/components/silke-form-schema/fields/utils/generate-title.ts +1 -3
- package/src/components/silke-form-schema/index.ts +1 -0
- package/src/components/silke-form-schema/silke-extended-fields-context.tsx +22 -0
- package/src/components/silke-form-schema/silke-schema-field.tsx +19 -6
- package/src/components/silke-icon/silke-icon.scss +3 -2
- package/src/components/silke-icon/silke-icon.tsx +7 -3
- package/src/components/silke-icon/silke-shape.tsx +3 -2
- package/src/components/silke-icon-picker/emoji-tab.tsx +2 -2
- package/src/components/silke-icon-picker/icons-tab.tsx +1 -1
- package/src/components/silke-icon-picker/silke-icon-picker.tsx +1 -1
- package/src/components/silke-iframe-portal/index.ts +4 -0
- package/src/components/silke-iframe-portal/silke-iframe-context.ts +6 -0
- package/src/components/silke-iframe-portal/silke-iframe-css-link.tsx +20 -0
- package/src/components/silke-iframe-portal/silke-iframe-portal.mdx +34 -0
- package/src/components/silke-iframe-portal/silke-iframe-portal.tsx +77 -0
- package/src/components/silke-iframe-portal/silke-iframe-script.tsx +20 -0
- package/src/components/silke-link/silke-link.scss +2 -2
- package/src/components/silke-link/silke-link.tsx +8 -9
- package/src/components/silke-list/silke-list.scss +1 -1
- package/src/components/silke-list-card/index.ts +1 -0
- package/src/components/silke-list-card/silke-list-card.mdx +50 -0
- package/src/components/silke-list-card/silke-list-card.scss +57 -0
- package/src/components/silke-list-card/silke-list-card.tsx +65 -0
- package/src/components/silke-loader/index.ts +1 -0
- package/src/components/silke-loader/silke-loader-overlay.tsx +63 -0
- package/src/components/silke-loader/silke-loader.scss +112 -0
- package/src/components/silke-loader/silke-loader.tsx +1 -0
- package/src/components/silke-modal/silke-confirmation-modal.tsx +1 -1
- package/src/components/silke-modal/silke-modal.mdx +1 -1
- package/src/components/silke-modal/silke-modal.scss +16 -10
- package/src/components/silke-modal/silke-modal.tsx +65 -47
- package/src/components/silke-navigation-link/silke-navigation-link.scss +69 -41
- package/src/components/silke-navigation-link/silke-navigation-link.tsx +26 -14
- package/src/components/silke-notification/confetti.tsx +164 -0
- package/src/components/silke-notification/silke-notification.mdx +137 -20
- package/src/components/silke-notification/silke-notification.scss +116 -89
- package/src/components/silke-notification/silke-notification.tsx +44 -113
- package/src/components/silke-object-field/silke-object-field.tsx +1 -1
- package/src/components/silke-overflow-menu/silke-overflow-menu.mdx +2 -2
- package/src/components/silke-overflow-menu/silke-overflow-menu.scss +12 -4
- package/src/components/silke-overflow-menu/silke-overflow-menu.tsx +53 -30
- package/src/components/silke-popover/silke-popover.mdx +2 -2
- package/src/components/silke-popover/silke-popover.tsx +23 -5
- package/src/components/silke-progress-indicator/silke-progress-indicator.scss +5 -5
- package/src/components/silke-radio-button/silke-radio-button-group.tsx +1 -1
- package/src/components/silke-radio-button/silke-radio-button.scss +24 -9
- package/src/components/silke-search-field/silke-search-field.tsx +10 -5
- package/src/components/silke-select-field/silke-select-field.mdx +11 -5
- package/src/components/silke-skeleton/silke-skeleton.scss +2 -2
- package/src/components/silke-slider/range-slider.scss +13 -10
- package/src/components/silke-slider/silke-slider.tsx +5 -0
- package/src/components/silke-sortable-list/silke-nested-sortable-item.tsx +105 -0
- package/src/components/silke-sortable-list/silke-nested-sortable-list.scss +37 -25
- package/src/components/silke-sortable-list/silke-nested-sortable-list.tsx +180 -127
- package/src/components/silke-sortable-list/silke-nested-sortable-utils.ts +53 -23
- package/src/components/silke-sortable-list/silke-sortable-item-wrapper.tsx +1 -1
- package/src/components/silke-sortable-list/silke-sortable-list.mdx +12 -16
- package/src/components/silke-sortable-list/silke-sortable-list.scss +39 -29
- package/src/components/silke-sortable-list/silke-sortable-list.tsx +27 -15
- package/src/components/silke-steps/index.ts +1 -0
- package/src/components/silke-steps/silke-steps.mdx +60 -0
- package/src/components/silke-steps/silke-steps.scss +14 -0
- package/src/components/silke-steps/silke-steps.tsx +53 -0
- package/src/components/silke-table/silke-table.mdx +44 -13
- package/src/components/silke-table/silke-table.scss +19 -9
- package/src/components/silke-table/silke-table.tsx +80 -71
- package/src/components/silke-table/table-row.tsx +11 -6
- package/src/components/silke-tabs/silke-tab.tsx +4 -0
- package/src/components/silke-tabs/silke-tabs.scss +18 -15
- package/src/components/silke-tabs/silke-tabs.tsx +4 -7
- package/src/components/silke-tag/silke-tag.mdx +36 -2
- package/src/components/silke-tag/silke-tag.scss +49 -30
- package/src/components/silke-tag/silke-tag.tsx +21 -6
- package/src/components/silke-text/silke-text-types.ts +2 -1
- package/src/components/silke-text/silke-text.mdx +28 -20
- package/src/components/silke-text/silke-text.scss +8 -7
- package/src/components/silke-text/silke-title.scss +1 -1
- package/src/components/silke-text-field/silke-text-field-outline.tsx +4 -4
- package/src/components/silke-text-field/silke-text-field.mdx +32 -14
- package/src/components/silke-text-field/silke-text-field.scss +41 -23
- package/src/components/silke-text-field/silke-text-field.tsx +13 -5
- package/src/components/silke-text-field/text-field-context.tsx +1 -1
- package/src/components/silke-theme-editor/index.ts +1 -0
- package/src/components/silke-theme-editor/silke-theme-editor.tsx +165 -0
- package/src/components/silke-tile/silke-tile.scss +13 -18
- package/src/components/silke-tile/silke-tile.tsx +11 -17
- package/src/components/silke-toggle/silke-toggle.scss +17 -9
- package/src/components/silke-toggle/silke-toggle.tsx +1 -1
- package/src/components/silke-toolbar/silke-toolbar.scss +1 -1
- package/src/components/silke-tooltip/silke-definition-tooltip.tsx +14 -6
- package/src/components/silke-tooltip/silke-icon-tooltip.tsx +48 -34
- package/src/components/silke-tooltip/silke-interactive-tooltip.tsx +5 -3
- package/src/components/silke-tooltip/silke-tooltip.mdx +69 -2
- package/src/components/silke-tooltip/silke-tooltip.scss +71 -46
- package/src/components/silke-tooltip/silke-tooltip.tsx +142 -52
- package/src/components/silke-tooltip/utils.ts +93 -0
- package/src/components/silke-upload-field/silke-upload-field.mdx +14 -0
- package/src/components/silke-upload-field/silke-upload-field.scss +26 -17
- package/src/components/silke-upload-field/silke-upload-field.tsx +37 -14
- package/src/docs/app.tsx +118 -25
- package/src/docs/components/code-block/code-block.scss +0 -2
- package/src/docs/components/code-block/code-block.tsx +17 -9
- package/src/hooks/drag-and-drop/use-drag.tsx +5 -1
- package/src/hooks/drag-and-drop/use-drop.tsx +5 -4
- package/src/icons.tsx +194 -10
- package/src/index.mdx +66 -1
- package/src/main.tsx +5 -2
- package/src/silke-theme-provider.tsx +51 -3
- package/src/styles/core.scss +56 -91
- package/webpack.docs.ts +1 -3
- package/webpack.config.ts +0 -131
package/src/docs/app.tsx
CHANGED
|
@@ -1,15 +1,43 @@
|
|
|
1
1
|
import { Keyboard } from '@vev/utils';
|
|
2
2
|
import { useStore } from './data/flux';
|
|
3
|
-
import {
|
|
3
|
+
import {
|
|
4
|
+
Flex,
|
|
5
|
+
SilkeAutocompleteField,
|
|
6
|
+
SilkeBox,
|
|
7
|
+
SilkeButton,
|
|
8
|
+
SilkeColorPicker,
|
|
9
|
+
SilkeColorPickerButton,
|
|
10
|
+
SilkeDivider,
|
|
11
|
+
SilkeDrawer,
|
|
12
|
+
SilkeList,
|
|
13
|
+
SilkeNavigationLink,
|
|
14
|
+
SilkeThemeEditor,
|
|
15
|
+
} from '../components';
|
|
4
16
|
import { last, startCase } from 'lodash';
|
|
5
|
-
import React, { useEffect } from 'react';
|
|
6
|
-
import {
|
|
7
|
-
|
|
8
|
-
|
|
17
|
+
import React, { useEffect, useRef, useState } from 'react';
|
|
18
|
+
import {
|
|
19
|
+
BrowserRouter,
|
|
20
|
+
Link,
|
|
21
|
+
Route,
|
|
22
|
+
Switch,
|
|
23
|
+
useHistory,
|
|
24
|
+
useLocation,
|
|
25
|
+
withRouter,
|
|
26
|
+
} from 'react-router-dom';
|
|
27
|
+
import { SilkeColorTheme, SilkeThemeProvider } from '../silke-theme-provider';
|
|
28
|
+
import { AppRoute, AppStore, loadAppRoutes } from './data/app';
|
|
9
29
|
import { DocsProvider } from './docs-provider';
|
|
10
30
|
|
|
11
31
|
const sleep = (timeout = 2000) => new Promise((resolve) => setTimeout(resolve, timeout));
|
|
32
|
+
|
|
33
|
+
const getRouteLabel = (r: AppRoute): string => {
|
|
34
|
+
return startCase(last(r.path.split('/'))?.replace(/(silke-|\.mdx$)/g, ''));
|
|
35
|
+
};
|
|
36
|
+
|
|
12
37
|
export default function App() {
|
|
38
|
+
const [colorTheme, setColorTheme] = useState({});
|
|
39
|
+
const [showThemeSettings, setShowThemeSettings] = useState(false);
|
|
40
|
+
|
|
13
41
|
useEffect(() => {
|
|
14
42
|
loadAppRoutes();
|
|
15
43
|
Keyboard.enable({});
|
|
@@ -23,43 +51,108 @@ export default function App() {
|
|
|
23
51
|
return URL.createObjectURL(file);
|
|
24
52
|
};
|
|
25
53
|
return (
|
|
26
|
-
<SilkeThemeProvider onFileUpload={handleFileUpload}>
|
|
54
|
+
<SilkeThemeProvider colors={colorTheme} onFileUpload={handleFileUpload}>
|
|
27
55
|
<DocsProvider>
|
|
28
56
|
<BrowserRouter>
|
|
29
57
|
<SilkeBox flex fill>
|
|
30
|
-
<SilkeBox column bg="
|
|
31
|
-
<
|
|
32
|
-
<
|
|
33
|
-
|
|
58
|
+
<SilkeBox column bg="neutral-5" style={{ width: 256 }} scroll>
|
|
59
|
+
<SilkeBox pad="l">
|
|
60
|
+
<Link to="/">
|
|
61
|
+
<img src="https://editor.vev.design/static/logo.svg" width="38" />
|
|
62
|
+
</Link>
|
|
63
|
+
</SilkeBox>
|
|
34
64
|
<AppMenu />
|
|
35
65
|
</SilkeBox>
|
|
36
|
-
|
|
37
|
-
|
|
66
|
+
|
|
67
|
+
<SilkeBox scroll column flex gap="xl" vPad="xl">
|
|
68
|
+
<AppToolbar onReqestShowTheme={() => setShowThemeSettings(true)} />
|
|
69
|
+
<SilkeBox column hPad="xxl">
|
|
70
|
+
<AppRouter />
|
|
71
|
+
</SilkeBox>
|
|
38
72
|
</SilkeBox>
|
|
39
73
|
</SilkeBox>
|
|
74
|
+
<SilkeDrawer open={showThemeSettings} onRequestClose={() => setShowThemeSettings(false)}>
|
|
75
|
+
<SilkeThemeEditor theme={colorTheme} onChange={setColorTheme} />
|
|
76
|
+
</SilkeDrawer>
|
|
40
77
|
</BrowserRouter>
|
|
41
78
|
</DocsProvider>
|
|
42
79
|
</SilkeThemeProvider>
|
|
43
80
|
);
|
|
44
81
|
}
|
|
45
82
|
|
|
83
|
+
function AppToolbar({ onReqestShowTheme }: { onReqestShowTheme: () => void }) {
|
|
84
|
+
const [showSearch, setShowSearch] = useState(false);
|
|
85
|
+
const history = useHistory();
|
|
86
|
+
const routes = useStore(AppStore, (s) => s.routes);
|
|
87
|
+
return (
|
|
88
|
+
<SilkeBox
|
|
89
|
+
hPad="xxl"
|
|
90
|
+
vPad="s"
|
|
91
|
+
gap="m"
|
|
92
|
+
style={{ position: 'sticky', top: -32, left: 0, zIndex: 1 }}
|
|
93
|
+
bg="neutral-0"
|
|
94
|
+
>
|
|
95
|
+
{showSearch ? (
|
|
96
|
+
<SilkeAutocompleteField
|
|
97
|
+
autoFocus
|
|
98
|
+
items={routes.map((route) => ({
|
|
99
|
+
label: getRouteLabel(route),
|
|
100
|
+
value: route.path,
|
|
101
|
+
}))}
|
|
102
|
+
onChange={(value: string) => {
|
|
103
|
+
history.push(value);
|
|
104
|
+
setShowSearch(false);
|
|
105
|
+
}}
|
|
106
|
+
/>
|
|
107
|
+
) : (
|
|
108
|
+
<SilkeButton icon="search" size="m" onClick={() => setShowSearch(true)} />
|
|
109
|
+
)}
|
|
110
|
+
<Flex />
|
|
111
|
+
|
|
112
|
+
<SilkeButton icon="undo" label="Reset theme" size="m" kind="secondary" />
|
|
113
|
+
<SilkeButton icon="settings" label="Theme settings" size="m" onClick={onReqestShowTheme} />
|
|
114
|
+
</SilkeBox>
|
|
115
|
+
);
|
|
116
|
+
}
|
|
117
|
+
|
|
46
118
|
export function AppMenu() {
|
|
47
119
|
const location = useLocation();
|
|
48
120
|
const routes = useStore(AppStore, (s) => s.routes);
|
|
121
|
+
|
|
122
|
+
const allRoutes = routes
|
|
123
|
+
.filter((r) => r.path !== '/')
|
|
124
|
+
.sort((p1, p2) => (p1.path < p2.path ? -1 : 1));
|
|
125
|
+
const baseRoutes = [];
|
|
126
|
+
const formRoutes = [];
|
|
127
|
+
for (const route of allRoutes) {
|
|
128
|
+
if (/-field|checkbox|form/.test(route.path)) {
|
|
129
|
+
formRoutes.push(route);
|
|
130
|
+
} else {
|
|
131
|
+
baseRoutes.push(route);
|
|
132
|
+
}
|
|
133
|
+
}
|
|
49
134
|
return (
|
|
50
|
-
<
|
|
51
|
-
{
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
135
|
+
<SilkeBox column>
|
|
136
|
+
{baseRoutes.map((r) => (
|
|
137
|
+
<SilkeNavigationLink
|
|
138
|
+
key={r.path}
|
|
139
|
+
link={r.path}
|
|
140
|
+
icon="widget"
|
|
141
|
+
active={location.pathname === r.path}
|
|
142
|
+
label={getRouteLabel(r)}
|
|
143
|
+
/>
|
|
144
|
+
))}
|
|
145
|
+
<SilkeDivider />
|
|
146
|
+
{formRoutes.map((r) => (
|
|
147
|
+
<SilkeNavigationLink
|
|
148
|
+
key={r.path}
|
|
149
|
+
link={r.path}
|
|
150
|
+
icon="widget"
|
|
151
|
+
active={location.pathname === r.path}
|
|
152
|
+
label={getRouteLabel(r)}
|
|
153
|
+
/>
|
|
154
|
+
))}
|
|
155
|
+
</SilkeBox>
|
|
63
156
|
);
|
|
64
157
|
}
|
|
65
158
|
|
|
@@ -5,7 +5,7 @@ import * as silke from '../../../index';
|
|
|
5
5
|
import styles from './code-block.scss';
|
|
6
6
|
import * as ipsum from '../../ipsum-generator';
|
|
7
7
|
|
|
8
|
-
const { SilkeBox } = silke;
|
|
8
|
+
const { SilkeBox, SilkeTile, ButtonContext } = silke;
|
|
9
9
|
const CodeScope = {
|
|
10
10
|
...silke,
|
|
11
11
|
ReactDOM,
|
|
@@ -30,17 +30,25 @@ export function CodeBlock({ children }: CodeBlockProps) {
|
|
|
30
30
|
const editorId = useMemo(() => ++lastEditorId, []);
|
|
31
31
|
return (
|
|
32
32
|
<LiveProvider code={children} transformCode={transformCode(editorId)} scope={CodeScope}>
|
|
33
|
-
<SilkeBox>
|
|
34
|
-
<SilkeBox
|
|
35
|
-
<
|
|
33
|
+
<SilkeBox column gap>
|
|
34
|
+
<SilkeBox gap>
|
|
35
|
+
<SilkeTile flex className={styles.preview}>
|
|
36
|
+
<ButtonContext kind="primary" size="m">
|
|
37
|
+
<LivePreview className="fill" />
|
|
38
|
+
</ButtonContext>
|
|
39
|
+
</SilkeTile>
|
|
40
|
+
<SilkeTile flex bg="neutral-5" column className={styles.code}>
|
|
41
|
+
<LiveEditor />
|
|
42
|
+
</SilkeTile>
|
|
36
43
|
</SilkeBox>
|
|
37
|
-
<SilkeBox
|
|
38
|
-
|
|
44
|
+
<SilkeBox
|
|
45
|
+
bg="error-30"
|
|
46
|
+
className={styles.error}
|
|
47
|
+
style={{ borderRadius: 'var(--border-radius-small)' }}
|
|
48
|
+
>
|
|
49
|
+
<LiveError style={{ margin: 10 }} />
|
|
39
50
|
</SilkeBox>
|
|
40
51
|
</SilkeBox>
|
|
41
|
-
<SilkeBox bg="error" className={styles.error}>
|
|
42
|
-
<LiveError style={{ margin: 10 }} />
|
|
43
|
-
</SilkeBox>
|
|
44
52
|
</LiveProvider>
|
|
45
53
|
);
|
|
46
54
|
}
|
|
@@ -44,7 +44,11 @@ export function useDrag<T>({
|
|
|
44
44
|
|
|
45
45
|
dragHandle.addEventListener('dragstart', handleDragStart);
|
|
46
46
|
dragHandle.addEventListener('dragend', handleDragEnd);
|
|
47
|
-
return () =>
|
|
47
|
+
return () => {
|
|
48
|
+
dragHandle.removeEventListener('dragstart', handleDragStart);
|
|
49
|
+
dragHandle.removeEventListener('dragend', handleDragStart);
|
|
50
|
+
dragHandle.removeAttribute('draggable');
|
|
51
|
+
};
|
|
48
52
|
}
|
|
49
53
|
}, [ref]);
|
|
50
54
|
|
|
@@ -11,8 +11,8 @@ export function useDrop<T>({
|
|
|
11
11
|
canDrop,
|
|
12
12
|
}: {
|
|
13
13
|
ref: MutableRefObject<HTMLElement | undefined | null>;
|
|
14
|
-
onOver?: (item: T) => void;
|
|
15
|
-
onDrop?: (item: T) => void;
|
|
14
|
+
onOver?: (item: T, e: DragEvent) => void;
|
|
15
|
+
onDrop?: (item: T, e: DragEvent) => void;
|
|
16
16
|
canDrop?: (item: T, e: DragEvent, state: SilkeDropState) => boolean;
|
|
17
17
|
}): SilkeDropState {
|
|
18
18
|
const [state, setState] = useState<SilkeDropState>('none');
|
|
@@ -33,7 +33,8 @@ export function useDrop<T>({
|
|
|
33
33
|
if (stateRef.current !== 'over' && canDropRef.current?.(data?.current, e, 'over')) {
|
|
34
34
|
stateRef.current = 'over';
|
|
35
35
|
setState('over');
|
|
36
|
-
|
|
36
|
+
|
|
37
|
+
onOverRef.current?.(data?.current, e);
|
|
37
38
|
}
|
|
38
39
|
};
|
|
39
40
|
|
|
@@ -43,7 +44,7 @@ export function useDrop<T>({
|
|
|
43
44
|
if (canDropRef.current?.(data?.current, e, 'drop')) {
|
|
44
45
|
stateRef.current = 'none';
|
|
45
46
|
setState('none');
|
|
46
|
-
onDropRef.current?.(data?.current);
|
|
47
|
+
onDropRef.current?.(data?.current, e);
|
|
47
48
|
}
|
|
48
49
|
};
|
|
49
50
|
|
package/src/icons.tsx
CHANGED
|
@@ -10,6 +10,7 @@ export const SilkeIconDefinitions = {
|
|
|
10
10
|
close: 'fal fa-times',
|
|
11
11
|
delete: 'fal fa-trash',
|
|
12
12
|
edit: 'fal fa-edit',
|
|
13
|
+
'edit.pen': 'fal fa-pen',
|
|
13
14
|
error: 'fas fa-exclamation',
|
|
14
15
|
help: 'fal fa-question-circle',
|
|
15
16
|
'check.circle.outline': 'fal fa-check-circle',
|
|
@@ -17,12 +18,16 @@ export const SilkeIconDefinitions = {
|
|
|
17
18
|
emoji: 'fal fa-smile',
|
|
18
19
|
'emoji.add': AddEmoji,
|
|
19
20
|
mention: 'fal fa-at',
|
|
21
|
+
share: 'fal fa-share-from-square',
|
|
22
|
+
'cloud.check': 'fal fa-cloud-check',
|
|
23
|
+
'cloud.slash': 'fal fa-cloud-slash',
|
|
20
24
|
|
|
21
25
|
menuMore: 'fal fa-ellipsis-v',
|
|
22
26
|
menu: 'fal fa-bars',
|
|
23
27
|
drag: 'fal fa-grip-lines',
|
|
24
28
|
remove: 'fal fa-minus',
|
|
25
29
|
'error.circle': 'fal fa-exclamation-circle',
|
|
30
|
+
'warning.triangle': 'fal fa-triangle-exclamation',
|
|
26
31
|
tooltip: 'fal fa-info-circle',
|
|
27
32
|
email: 'fal fa-envelope',
|
|
28
33
|
password: 'fal fa-key',
|
|
@@ -32,14 +37,14 @@ export const SilkeIconDefinitions = {
|
|
|
32
37
|
rollback: 'fal fa-history',
|
|
33
38
|
settings: 'fal fa-cog',
|
|
34
39
|
search: 'fal fa-search',
|
|
35
|
-
filter: 'fal fa-bars-
|
|
40
|
+
filter: 'fal fa-bars-sort',
|
|
36
41
|
copy: 'fal fa-copy',
|
|
37
42
|
paste: 'fal fa-paste',
|
|
38
43
|
random: 'fal fa-random',
|
|
39
44
|
question: 'fal fa-question-circle',
|
|
40
45
|
send: 'fal fa-paper-plane',
|
|
41
|
-
link: 'fal fa-link',
|
|
42
|
-
unlink: 'fal fa-
|
|
46
|
+
link: 'fal fa-link-simple',
|
|
47
|
+
unlink: 'fal fa-link-simple-slash',
|
|
43
48
|
'link.external': 'fal fa-external-link',
|
|
44
49
|
flag: 'fal fa-flag',
|
|
45
50
|
sum: 'fal fa-sigma',
|
|
@@ -60,13 +65,23 @@ export const SilkeIconDefinitions = {
|
|
|
60
65
|
'mouse.pointer': 'fal fa-mouse-pointer',
|
|
61
66
|
'mouse.drag': 'fal fa-hand',
|
|
62
67
|
dot: 'fas fa-circle-small',
|
|
68
|
+
'dots.vertical': 'fal fa-ellipsis-stroke-vertical',
|
|
69
|
+
'dots.horizontal': 'fal fa-ellipsis-stroke-vertical fa-rotate-90',
|
|
63
70
|
star: 'fa-solid fa-star',
|
|
64
71
|
eyeDropper: 'fal fa-eye-dropper',
|
|
72
|
+
log: 'fal fa-binary',
|
|
73
|
+
dashboard: 'fal fa-grid-2',
|
|
74
|
+
test: 'fal fa-flask-vial',
|
|
75
|
+
guest: 'fal fa-user-astronaut',
|
|
76
|
+
'network.on': 'fal fa-wifi',
|
|
77
|
+
'network.off': 'fal fa-wifi-slash',
|
|
78
|
+
grid: 'fal fa-grid',
|
|
65
79
|
|
|
66
80
|
notification: 'fal fa-bell',
|
|
67
81
|
'notification.new': 'fal fa-bell-on',
|
|
68
82
|
|
|
69
83
|
package: 'fal fa-cube',
|
|
84
|
+
'package.open': 'fal fa-box-open',
|
|
70
85
|
'select.all': 'fal fa-check-double',
|
|
71
86
|
ban: 'fas fa-ban',
|
|
72
87
|
'error.triangle': 'fal fa-exclamation-triangle',
|
|
@@ -89,9 +104,9 @@ export const SilkeIconDefinitions = {
|
|
|
89
104
|
'arrow.left': 'fal fa-arrow-left',
|
|
90
105
|
'arrow.right': 'fal fa-arrow-right',
|
|
91
106
|
'arrow.up': 'fal fa-arrow-up',
|
|
92
|
-
'chevron.down': '
|
|
93
|
-
'chevron.up': '
|
|
94
|
-
'chevron.right': '
|
|
107
|
+
'chevron.down': 'fal fa-chevron-down',
|
|
108
|
+
'chevron.up': 'fal fa-chevron-up',
|
|
109
|
+
'chevron.right': 'fal fa-chevron-right',
|
|
95
110
|
'arrow.up.right': 'fa-solid fa-arrow-up-right',
|
|
96
111
|
'caret.down': 'fas fa-caret-down',
|
|
97
112
|
'caret.up': 'fas fa-caret-up',
|
|
@@ -136,10 +151,11 @@ export const SilkeIconDefinitions = {
|
|
|
136
151
|
user: 'fal fa-user',
|
|
137
152
|
'user.add': 'fal fa-user-plus',
|
|
138
153
|
'user.secret': 'fal fa-user-secret',
|
|
154
|
+
'user.history': 'fal fa-user-clock',
|
|
139
155
|
integrations: IntegrationsIcon,
|
|
140
156
|
users: 'fal fa-user-friends',
|
|
141
157
|
'users-class': 'fal fa-users-class',
|
|
142
|
-
team: '
|
|
158
|
+
team: 'fal fa-users',
|
|
143
159
|
workspace: 'fal fa-folder',
|
|
144
160
|
admin: 'fal fa-alicorn',
|
|
145
161
|
hosting: 'fal fa-server',
|
|
@@ -154,6 +170,7 @@ export const SilkeIconDefinitions = {
|
|
|
154
170
|
address: 'fal fa-id-card',
|
|
155
171
|
'credit-card': 'fal fa-credit-card',
|
|
156
172
|
money: 'fal fa-money-bill',
|
|
173
|
+
dynamic: 'fa-light fa-bolt-lightning',
|
|
157
174
|
// EDITOR ICONS
|
|
158
175
|
'editor.design': 'fal fa-vector-square',
|
|
159
176
|
'editor.content': 'fal fa-i-cursor',
|
|
@@ -163,18 +180,22 @@ export const SilkeIconDefinitions = {
|
|
|
163
180
|
image: 'fal fa-image',
|
|
164
181
|
video: 'fal fa-video',
|
|
165
182
|
fill: 'fal fa-fill-drip',
|
|
183
|
+
opacity: 'fal fa-droplet-percent',
|
|
166
184
|
'object.group': 'fal fa-object-group',
|
|
167
185
|
'object.ungroup': 'fal fa-object-ungroup',
|
|
168
186
|
pin: 'fal fa-map-pin',
|
|
169
|
-
'main-component':
|
|
187
|
+
'main-component': MainComponent,
|
|
170
188
|
section: Section,
|
|
171
|
-
frame: 'fal fa-
|
|
189
|
+
frame: 'fal fa-frame',
|
|
172
190
|
'frame.row': 'fal fa-diagram-cells fa-rotate-90',
|
|
173
191
|
'frame.column': 'fal fa-diagram-cells',
|
|
174
192
|
layers: 'fal fa-layer-group',
|
|
175
193
|
addon: 'fal fa-puzzle-piece',
|
|
176
194
|
widget: 'fal fa-cube',
|
|
177
195
|
form: 'fal fa-input-text',
|
|
196
|
+
'curly-brackets': 'far fa-brackets-curly',
|
|
197
|
+
expand: 'fal fa-expand',
|
|
198
|
+
'custom-component': CustomComponentIcon,
|
|
178
199
|
|
|
179
200
|
'project-plan': ProjectPlanRibbon,
|
|
180
201
|
diamond: 'fa-regular fa-gem',
|
|
@@ -193,6 +214,16 @@ export const SilkeIconDefinitions = {
|
|
|
193
214
|
'align.objects.distribute.horizontal': 'fal fa-distribute-spacing-horizontal',
|
|
194
215
|
'align.objects.distribute.vertical': 'fal fa-distribute-spacing-vertical',
|
|
195
216
|
|
|
217
|
+
'placement.center': PlacementCenter,
|
|
218
|
+
'placement.top': PlacementTop,
|
|
219
|
+
'placement.bottom': PlacementBottom,
|
|
220
|
+
|
|
221
|
+
'rotate.left': 'fal fa-rotate-left',
|
|
222
|
+
'rotate.right': 'fal fa-rotate-right',
|
|
223
|
+
|
|
224
|
+
'flip.horizontal': FlipIconHorizontal,
|
|
225
|
+
'flip.vertical': FlipIconVertical,
|
|
226
|
+
|
|
196
227
|
'border.top': 'fal fa-border-top',
|
|
197
228
|
'border.top.left': 'fal fa-border-top-left',
|
|
198
229
|
'border.top.right': 'fal fa-border-top-left fa-rotate-90',
|
|
@@ -212,11 +243,12 @@ export const SilkeIconDefinitions = {
|
|
|
212
243
|
signout: 'fal fa-sign-out',
|
|
213
244
|
tag: 'fal fa-tag',
|
|
214
245
|
'file.export': 'fal fa-file-export',
|
|
215
|
-
home: '
|
|
246
|
+
home: 'fal fa-house',
|
|
216
247
|
qr: 'fal fa-qrcode',
|
|
217
248
|
|
|
218
249
|
list: 'fal fa-list',
|
|
219
250
|
'list.ol': 'fal fa-list-ol',
|
|
251
|
+
'list.check': 'fal fa-list-check',
|
|
220
252
|
table: 'fal fa-table',
|
|
221
253
|
text: 'fal fa-text',
|
|
222
254
|
'text.subscript': 'fal fa-subscript',
|
|
@@ -254,12 +286,16 @@ export const SilkeIconDefinitions = {
|
|
|
254
286
|
joomla: 'fab fa-joomla',
|
|
255
287
|
shopify: 'fab fa-shopify',
|
|
256
288
|
figma: 'fab fa-figma',
|
|
289
|
+
ceros: Ceros,
|
|
257
290
|
import: 'fal fa-file-import',
|
|
258
291
|
stripe: 'fab fa-stripe',
|
|
259
292
|
okta: 'fa-solid fa-circle-dot',
|
|
260
293
|
linkedin: 'fab fa-linkedin',
|
|
261
294
|
twitter: 'fab fa-twitter',
|
|
262
295
|
react: 'fab fa-react',
|
|
296
|
+
sass: 'fab fa-sass',
|
|
297
|
+
typescript: TypescriptIcon,
|
|
298
|
+
html5: 'fab fa-html5',
|
|
263
299
|
|
|
264
300
|
// Card icons
|
|
265
301
|
'American Express': 'fab fa-cc-amex',
|
|
@@ -290,8 +326,32 @@ export const SilkeIconDefinitions = {
|
|
|
290
326
|
polarArea: 'fa-solid fa-chart-radar',
|
|
291
327
|
bubble: 'fa-solid fa-chart-scatter-bubble',
|
|
292
328
|
scatter: 'fa-solid fa-chart-scatter',
|
|
329
|
+
|
|
330
|
+
// Content children
|
|
331
|
+
contentChild: 'fa-light fa-square-caret-right',
|
|
332
|
+
contentChildParent: ContentChildParent,
|
|
293
333
|
};
|
|
294
334
|
|
|
335
|
+
function CustomComponentIcon({ className }: { className?: string }) {
|
|
336
|
+
return (
|
|
337
|
+
<svg
|
|
338
|
+
className={className}
|
|
339
|
+
width="40"
|
|
340
|
+
height=""
|
|
341
|
+
viewBox="0 0 40 40"
|
|
342
|
+
fill="none"
|
|
343
|
+
xmlns="http://www.w3.org/2000/svg"
|
|
344
|
+
>
|
|
345
|
+
<path
|
|
346
|
+
fillRule="evenodd"
|
|
347
|
+
clipRule="evenodd"
|
|
348
|
+
d="M3.16277 15.5383L6.0783 18.2352C6.00542 18.8183 6.00542 19.4743 6.00542 20.0574C6.00542 20.7134 6.00542 21.3694 6.0783 21.9525L3.16277 24.6493C2.361 25.3782 2.14233 26.5444 2.72544 27.492L4.91209 31.3551C5.42231 32.3026 6.58852 32.7399 7.60896 32.3755L11.3992 31.2093C12.4196 31.9382 13.5129 32.5213 14.6062 33.0315L15.4809 36.8946C15.6996 37.9879 16.6471 38.7168 17.7404 38.7168H22.1866C23.28 38.7168 24.2275 37.9879 24.4462 36.8946L25.3208 33.0315C26.4142 32.5213 27.5075 31.9382 28.5279 31.2093L32.3181 32.3755C33.3386 32.7399 34.5048 32.3026 35.015 31.3551L37.2016 27.492C37.7847 26.5444 37.5661 25.3782 36.7643 24.6493L33.8488 21.9525C33.9217 21.3694 33.9946 20.7134 33.9946 20.0574C33.9946 19.4743 33.9217 18.8183 33.8488 18.2352L36.7643 15.5383C37.5661 14.8094 37.7847 13.6432 37.2016 12.6956L35.015 8.83256C34.5048 7.88501 33.3386 7.44768 32.3181 7.81213L28.5279 8.97834C27.5075 8.24946 26.4142 7.59346 25.3208 7.15613L24.4462 3.29305C24.2275 2.19972 23.28 1.39795 22.1866 1.39795H17.7404C16.6471 1.39795 15.6996 2.19972 15.4809 3.29305L14.6062 7.15613C13.5129 7.59346 12.4196 8.24946 11.3992 8.97834L7.60896 7.81213C6.58852 7.44768 5.42231 7.88501 4.91209 8.83256L2.72544 12.6956C2.14233 13.6432 2.361 14.8094 3.16277 15.5383ZM11.9094 11.6023L12.8569 10.8734C13.6587 10.2174 14.5334 9.70722 15.5538 9.26989L16.6471 8.83256L17.7404 3.73038H22.1866L23.28 8.83256L24.3733 9.26989C25.3937 9.70722 26.2684 10.2174 27.0702 10.8734L28.0177 11.6023L32.9741 9.99878L35.2337 13.8619L31.3706 17.3605L31.5163 18.5267L31.5164 18.5268C31.5892 19.037 31.6621 19.5472 31.6621 20.0574C31.6621 20.6405 31.5892 21.1507 31.5164 21.6609L31.5163 21.6609L31.3706 22.8271L35.2337 26.3258L32.9741 30.1889L28.0177 28.5853L27.0702 29.3142C26.2684 29.9702 25.3937 30.4804 24.3733 30.8448L23.28 31.3551L22.1866 36.3844H17.7404L16.6471 31.3551L15.5538 30.8448C14.5334 30.4804 13.6587 29.9702 12.8569 29.3142L11.9094 28.5853L6.95296 30.1889L4.69342 26.3258L8.55651 22.8271L8.41073 21.6609C8.33784 21.1507 8.33784 20.6405 8.33784 20.0574C8.33784 19.5472 8.33784 19.0369 8.41073 18.5267L8.55651 17.3605L4.69342 13.8619L6.95296 9.99878L11.9094 11.6023ZM18.2556 23.1221L14.9276 19.7698L18.2554 16.442C18.6527 16.0724 18.6535 15.4321 18.2578 15.0614C17.8871 14.6657 17.2468 14.6665 16.8773 15.0638L12.8505 19.0906C12.4524 19.4609 12.4524 20.103 12.8505 20.4733L16.8773 24.5001C17.2468 24.8974 17.8871 24.8982 18.2578 24.5025C18.6534 24.1319 18.6527 23.4918 18.2556 23.1221ZM18.1356 24.3802C18.4631 24.0779 18.4631 23.5487 18.1356 23.2464L14.6837 19.7694L18.1356 16.3175C18.4631 16.0151 18.4631 15.486 18.1356 15.1837C17.992 15.0282 17.7974 14.9465 17.6002 14.9387C17.7974 14.9466 17.9919 15.0282 18.1354 15.1837C18.4629 15.486 18.4629 16.0151 18.1354 16.3175L14.6835 19.7693L18.1354 23.2464C18.4629 23.5487 18.4629 24.0779 18.1354 24.3802C17.9917 24.5359 17.7967 24.6176 17.5992 24.6253C17.7967 24.6177 17.9918 24.536 18.1356 24.3802ZM21.7171 15.0614C21.3214 15.4321 21.3222 16.0724 21.7195 16.442L25.0473 19.7698L21.7193 23.1221C21.3222 23.4918 21.3215 24.1319 21.7171 24.5025C22.0878 24.8982 22.7281 24.8974 23.0977 24.5001L27.1244 20.4733C27.5225 20.103 27.5225 19.4609 27.1244 19.0906L23.0977 15.0638C22.7281 14.6665 22.0878 14.6657 21.7171 15.0614ZM22.9732 15.1837C22.8386 15.0379 22.6592 14.957 22.4748 14.941C22.6591 14.9571 22.8385 15.038 22.973 15.1837L27.0044 19.215C27.3319 19.5174 27.3319 20.0465 27.0044 20.3489L22.973 24.3802C22.8293 24.5359 22.6343 24.6176 22.4368 24.6253C22.6344 24.6177 22.8294 24.536 22.9732 24.3802L27.0045 20.3489C27.3321 20.0465 27.3321 19.5174 27.0045 19.215L22.9732 15.1837Z"
|
|
349
|
+
fill="#FCFCFC"
|
|
350
|
+
/>
|
|
351
|
+
</svg>
|
|
352
|
+
);
|
|
353
|
+
}
|
|
354
|
+
|
|
295
355
|
function DropcapIcon() {
|
|
296
356
|
return (
|
|
297
357
|
<svg width={16} height={13} viewBox="0 0 16 13">
|
|
@@ -448,3 +508,127 @@ function CommentNew() {
|
|
|
448
508
|
</div>
|
|
449
509
|
);
|
|
450
510
|
}
|
|
511
|
+
|
|
512
|
+
function Ceros() {
|
|
513
|
+
return (
|
|
514
|
+
<svg width="16" height="8">
|
|
515
|
+
<path d="m7.26 1.48-.7 1.06c-.22-.2-.42-.39-.63-.56a2.87 2.87 0 0 0-4.1.32 2.74 2.74 0 0 0 .3 3.7c1.08.98 2.64.98 3.65-.09.53-.56.96-1.23 1.4-1.87.48-.69.91-1.4 1.39-2.09.9-1.29 2.1-2.03 3.71-1.94a3.97 3.97 0 0 1 .3 7.91 4.27 4.27 0 0 1-3.84-1.4l.7-1.07c.26.23.5.46.76.66 1.51 1.14 3.68.6 4.35-1.08a2.74 2.74 0 0 0-1.07-3.33 2.56 2.56 0 0 0-3.43.53c-.59.71-1.06 1.53-1.6 2.3-.5.7-.96 1.46-1.53 2.12A3.97 3.97 0 1 1 2.96.17a4.25 4.25 0 0 1 4.3 1.31Z" />
|
|
516
|
+
</svg>
|
|
517
|
+
);
|
|
518
|
+
}
|
|
519
|
+
|
|
520
|
+
function PlacementCenter() {
|
|
521
|
+
return (
|
|
522
|
+
<svg viewBox="0 0 24 24">
|
|
523
|
+
<path
|
|
524
|
+
fillRule="evenodd"
|
|
525
|
+
clipRule="evenodd"
|
|
526
|
+
d="M20 2H4C3.44771 2 3 2.44772 3 3V21C3 21.5523 3.44772 22 4 22H20C20.5523 22 21 21.5523 21 21V3C21 2.44772 20.5523 2 20 2ZM4 1C2.89543 1 2 1.89543 2 3V21C2 22.1046 2.89543 23 4 23H20C21.1046 23 22 22.1046 22 21V3C22 1.89543 21.1046 1 20 1H4Z"
|
|
527
|
+
/>
|
|
528
|
+
<rect x="5" y="8" width="14" height="8" rx="1" style={{ fill: 'currentColor' }} />
|
|
529
|
+
</svg>
|
|
530
|
+
);
|
|
531
|
+
}
|
|
532
|
+
|
|
533
|
+
function PlacementTop() {
|
|
534
|
+
return (
|
|
535
|
+
<svg viewBox="0 0 24 24">
|
|
536
|
+
<path
|
|
537
|
+
fillRule="evenodd"
|
|
538
|
+
clipRule="evenodd"
|
|
539
|
+
d="M20 2H4C3.44771 2 3 2.44772 3 3V21C3 21.5523 3.44772 22 4 22H20C20.5523 22 21 21.5523 21 21V3C21 2.44772 20.5523 2 20 2ZM4 1C2.89543 1 2 1.89543 2 3V21C2 22.1046 2.89543 23 4 23H20C21.1046 23 22 22.1046 22 21V3C22 1.89543 21.1046 1 20 1H4Z"
|
|
540
|
+
/>
|
|
541
|
+
<rect x="5" y="4" width="14" height="5" rx="1" style={{ fill: 'currentColor' }} />
|
|
542
|
+
</svg>
|
|
543
|
+
);
|
|
544
|
+
}
|
|
545
|
+
|
|
546
|
+
function PlacementBottom() {
|
|
547
|
+
return (
|
|
548
|
+
<svg viewBox="0 0 24 24">
|
|
549
|
+
<path
|
|
550
|
+
fillRule="evenodd"
|
|
551
|
+
clipRule="evenodd"
|
|
552
|
+
d="M20 2H4C3.44771 2 3 2.44772 3 3V21C3 21.5523 3.44772 22 4 22H20C20.5523 22 21 21.5523 21 21V3C21 2.44772 20.5523 2 20 2ZM4 1C2.89543 1 2 1.89543 2 3V21C2 22.1046 2.89543 23 4 23H20C21.1046 23 22 22.1046 22 21V3C22 1.89543 21.1046 1 20 1H4Z"
|
|
553
|
+
/>
|
|
554
|
+
<rect x="5" y="15" width="14" height="5" rx="1" style={{ fill: 'currentColor' }} />
|
|
555
|
+
</svg>
|
|
556
|
+
);
|
|
557
|
+
}
|
|
558
|
+
|
|
559
|
+
function MainComponent() {
|
|
560
|
+
return (
|
|
561
|
+
<svg viewBox="0 0 16 16">
|
|
562
|
+
<path
|
|
563
|
+
fillRule="evenodd"
|
|
564
|
+
clipRule="evenodd"
|
|
565
|
+
d="M8 6C9.1598 6 10.0273 5.1598 10.0273 4C10.0273 2.8402 9.1598 1.99219 8 1.99219C6.8402 1.99219 5.98828 2.8402 5.98828 4C5.98828 5.1598 6.8402 6 8 6ZM8 7C9.65685 7 11 5.65685 11 4C11 2.34315 9.65685 1 8 1C6.34315 1 5 2.34315 5 4C5 5.65685 6.34315 7 8 7Z"
|
|
566
|
+
/>
|
|
567
|
+
<path
|
|
568
|
+
fillRule="evenodd"
|
|
569
|
+
clipRule="evenodd"
|
|
570
|
+
d="M12.0156 13C13.1754 13 14.043 12.1598 14.043 11C14.043 9.8402 13.1754 8.99219 12.0156 8.99219C10.8558 8.99219 10.0039 9.8402 10.0039 11C10.0039 12.1598 10.8558 13 12.0156 13ZM12.0156 14C13.6725 14 15.0156 12.6569 15.0156 11C15.0156 9.34315 13.6725 8 12.0156 8C10.3588 8 9.01562 9.34315 9.01562 11C9.01562 12.6569 10.3588 14 12.0156 14Z"
|
|
571
|
+
/>
|
|
572
|
+
<path
|
|
573
|
+
fillRule="evenodd"
|
|
574
|
+
clipRule="evenodd"
|
|
575
|
+
d="M3.98438 13C5.14417 13 6.01172 12.1598 6.01172 11C6.01172 9.8402 5.14417 8.99219 3.98438 8.99219C2.82458 8.99219 1.97266 9.8402 1.97266 11C1.97266 12.1598 2.82458 13 3.98438 13ZM3.98438 14C5.64123 14 6.98438 12.6569 6.98438 11C6.98438 9.34315 5.64123 8 3.98438 8C2.32752 8 0.984375 9.34315 0.984375 11C0.984375 12.6569 2.32752 14 3.98438 14Z"
|
|
576
|
+
/>
|
|
577
|
+
</svg>
|
|
578
|
+
);
|
|
579
|
+
}
|
|
580
|
+
|
|
581
|
+
function TypescriptIcon() {
|
|
582
|
+
return (
|
|
583
|
+
<svg height="512" width="512">
|
|
584
|
+
<rect fill="#3178c6" height="512" rx="50" width="512" />
|
|
585
|
+
<rect fill="#3178c6" height="512" rx="50" width="512" />
|
|
586
|
+
<path
|
|
587
|
+
clipRule="evenodd"
|
|
588
|
+
d="M317 407.4v50c8 4.3 17.7 7.4 28.8 9.5a189 189 0 0 0 69.3-.3c10.8-2.3 20.3-6.1 28.5-11.4 8-5.2 14.5-12.1 19.3-20.6s7.1-19 7.1-31.6c0-9-1.4-17-4-23.8s-6.7-13-11.8-18.2c-5.1-5.4-11.2-10.1-18.4-14.4s-15.2-8.2-24.2-12c-6.5-2.6-12.4-5.3-17.7-7.8a89.8 89.8 0 0 1-13.3-7.8 34.1 34.1 0 0 1-8.4-8.5c-2-3-3-6.3-3-10 0-3.5.9-6.6 2.7-9.4s4.2-5.1 7.5-7.1c3.2-2 7.2-3.5 11.9-4.6a69 69 0 0 1 15.6-1.7 99.3 99.3 0 0 1 53.2 15.7v-46.8c-7.6-3-15.9-5-25-6.5s-19.3-2.1-31-2.1c-11.9 0-23.2 1.3-33.8 3.8s-20 6.6-28 12a59.8 59.8 0 0 0-19.3 20.7c-4.7 8.4-7 18.5-7 30.1 0 15 4.3 27.7 13 38.2a98.2 98.2 0 0 0 39.1 26.8c6.9 2.8 13.3 5.5 19.3 8.3s11 5.5 15.4 8.4c4.3 3 7.7 6.1 10.2 9.5a19.4 19.4 0 0 1 1.4 20.8c-1.5 2.7-3.9 5.1-7 7.2s-7.2 3.6-12 4.7a71.5 71.5 0 0 1-16.6 1.8 95.1 95.1 0 0 1-61.9-22.9zm-84.2-123.3H297V243H118v41h64v183h50.8z"
|
|
589
|
+
fill="#fff"
|
|
590
|
+
fillRule="evenodd"
|
|
591
|
+
/>
|
|
592
|
+
</svg>
|
|
593
|
+
);
|
|
594
|
+
}
|
|
595
|
+
|
|
596
|
+
function FlipIconVertical() {
|
|
597
|
+
return (
|
|
598
|
+
<svg width="16" height="15" fill="none">
|
|
599
|
+
<path
|
|
600
|
+
fill="#currentColor"
|
|
601
|
+
fillRule="evenodd"
|
|
602
|
+
d="M8.6208 4.4973a.9088.9088 0 0 1-1.2417 0l-2.617-2.4478c-.6022-.5632-.2037-1.5726.6208-1.5726h5.2342c.8244 0 1.2229 1.0094.6208 1.5726L8.6208 4.4973ZM5.2136 13.0581l2.6171-2.4478a.248.248 0 0 1 .3386 0l2.6171 2.4478c.1642.1535.0556.4289-.1693.4289H5.3829c-.2248 0-.3335-.2754-.1693-.4289Zm2.1656-2.9306a.909.909 0 0 1 1.2417 0l2.617 2.4478c.6022.5632.2036 1.5726-.6208 1.5726H5.3829c-.8244 0-1.2229-1.0094-.6208-1.5726l2.6171-2.4478ZM15.1288 7.4648a.4544.4544 0 0 1-.4544.4544h-.445a.4544.4544 0 0 1 0-.9089h.445c.251 0 .4544.2035.4544.4545Zm-2.2248 0a.4544.4544 0 0 1-.4544.4544h-.8899a.4545.4545 0 1 1 0-.9089h.8899c.251 0 .4544.2035.4544.4545Zm-2.6697 0a.4545.4545 0 0 1-.4545.4544H8.89a.4544.4544 0 1 1 0-.9089h.89c.2509 0 .4544.2035.4544.4545Zm-2.6698 0a.4544.4544 0 0 1-.4544.4544h-.89a.4544.4544 0 1 1 0-.9089h.89c.251 0 .4544.2035.4544.4545Zm-2.6698 0a.4544.4544 0 0 1-.4544.4544h-.89a.4544.4544 0 1 1 0-.9089h.89c.251 0 .4544.2035.4544.4545Zm-2.6697 0a.4544.4544 0 0 1-.4545.4544h-.445a.4544.4544 0 0 1 0-.9089h.445c.251 0 .4545.2035.4545.4545Z"
|
|
603
|
+
clipRule="evenodd"
|
|
604
|
+
/>
|
|
605
|
+
</svg>
|
|
606
|
+
);
|
|
607
|
+
}
|
|
608
|
+
|
|
609
|
+
function FlipIconHorizontal() {
|
|
610
|
+
return (
|
|
611
|
+
<svg width="16" height="17" fill="none">
|
|
612
|
+
<g fill="#currentColor" fillRule="evenodd" clipRule="evenodd">
|
|
613
|
+
<path d="M4.9972 7.8792a.9088.9088 0 0 1 0 1.2417l-2.4478 2.617c-.5631.6022-1.5726.2037-1.5726-.6208V5.8829c0-.8244 1.0095-1.223 1.5726-.6208l2.4478 2.6171ZM13.5581 11.2864l-2.4478-2.6171a.248.248 0 0 1 0-.3386l2.4478-2.6171c.1535-.1642.4289-.0556.4289.1693v5.2342c0 .2248-.2754.3335-.4289.1693Zm-2.9306-2.1656a.909.909 0 0 1 0-1.2417l2.4478-2.617c.5632-.6022 1.5726-.2036 1.5726.6208v5.2342c0 .8244-1.0094 1.2229-1.5726.6208l-2.4478-2.6171ZM7.9648 1.3712c.251 0 .4544.2034.4544.4544v.445a.4544.4544 0 0 1-.9088 0v-.445c0-.251.2034-.4544.4544-.4544Zm0 2.2248c.251 0 .4544.2034.4544.4544v.89a.4545.4545 0 1 1-.9088 0v-.89c0-.251.2034-.4544.4544-.4544Zm0 2.6697c.251 0 .4544.2035.4544.4545V7.61a.4544.4544 0 1 1-.9088 0v-.89c0-.2509.2034-.4544.4544-.4544Zm0 2.6698c.251 0 .4544.2035.4544.4544v.89a.4544.4544 0 0 1-.9088 0v-.89c0-.251.2034-.4544.4544-.4544Zm0 2.6698c.251 0 .4544.2034.4544.4544v.8899a.4544.4544 0 1 1-.9088 0v-.8899c0-.251.2034-.4544.4544-.4544Zm0 2.6697c.251 0 .4544.2035.4544.4545v.4449a.4544.4544 0 1 1-.9088 0v-.4449c0-.251.2034-.4545.4544-.4545Z" />
|
|
614
|
+
</g>
|
|
615
|
+
</svg>
|
|
616
|
+
);
|
|
617
|
+
}
|
|
618
|
+
|
|
619
|
+
function ContentChildParent() {
|
|
620
|
+
return (
|
|
621
|
+
<svg width="17" height="16" viewBox="0 0 17 16" fill="none">
|
|
622
|
+
<path
|
|
623
|
+
d="M7.02297 6.52667L9.40281 8.90652C9.72509 9.204 9.72509 9.72459 9.40281 10.0221L7.02297 12.4019C6.52717 12.8977 5.68431 12.5507 5.68431 11.8317V7.07205C5.68431 6.37793 6.52717 6.03087 7.02297 6.52667ZM6.47759 11.8317L8.85743 9.4519L6.47759 7.07205V11.8317ZM11.2373 3.89893C12.1049 3.89893 12.8238 4.61784 12.8238 5.48549V13.4183C12.8238 14.3108 12.1049 15.0049 11.2373 15.0049H3.30446C2.41202 15.0049 1.7179 14.3108 1.7179 13.4183V5.48549C1.7179 4.61784 2.41202 3.89893 3.30446 3.89893H11.2373ZM12.0306 13.4183V5.48549C12.0306 5.06406 11.6587 4.69221 11.2373 4.69221H3.30446C2.85824 4.69221 2.51118 5.06406 2.51118 5.48549V13.4183C2.51118 13.8645 2.85824 14.2116 3.30446 14.2116H11.2373C11.6587 14.2116 12.0306 13.8645 12.0306 13.4183Z"
|
|
624
|
+
fill="#currentColor"
|
|
625
|
+
/>
|
|
626
|
+
<path
|
|
627
|
+
fillRule="evenodd"
|
|
628
|
+
clipRule="evenodd"
|
|
629
|
+
d="M15.6817 2.59047C15.6817 1.72282 14.9628 1.00391 14.0952 1.00391H6.16235C5.30149 1.00391 4.62517 1.67283 4.57837 2.49892H5.37454C5.42036 2.11663 5.74876 1.79719 6.16235 1.79719H14.0952C14.5166 1.79719 14.8884 2.16904 14.8884 2.59047V10.5233C14.8884 10.9252 14.5868 11.2466 14.219 11.3065V12.1051C15.0302 12.0428 15.6817 11.3729 15.6817 10.5233V2.59047Z"
|
|
630
|
+
fill="#currentColor"
|
|
631
|
+
/>
|
|
632
|
+
</svg>
|
|
633
|
+
);
|
|
634
|
+
}
|