@vev/silke 1.0.21 → 1.0.23
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 +15 -0
- package/dist/index.js +22 -22
- package/dist/index.js.map +4 -4
- package/dist/silke/src/components/silke-autocomplete-field/silke-autocomplete-field.d.ts +4 -0
- package/dist/silke/src/components/silke-breadcrumbs/silke-breadcrumb.d.ts +2 -1
- package/dist/silke/src/components/silke-button/index.d.ts +1 -0
- package/dist/silke/src/components/silke-button/silke-button.d.ts +2 -0
- package/dist/silke/src/components/silke-button/silke-dropdown-button.d.ts +17 -0
- package/dist/silke/src/components/silke-card/silke-card.d.ts +1 -1
- package/dist/silke/src/components/silke-color-swatches/silke-swatches.d.ts +2 -1
- package/dist/silke/src/components/silke-context-menu/silke-context-menu.d.ts +3 -1
- package/dist/silke/src/components/silke-css-number-field/index.d.ts +1 -0
- package/dist/silke/src/components/silke-css-number-field/silke-css-context.d.ts +7 -0
- package/dist/silke/src/components/silke-css-number-field/silke-css-number-field.d.ts +3 -0
- package/dist/silke/src/components/silke-css-number-field/variable-picker.d.ts +17 -0
- package/dist/silke/src/components/silke-form-schema/fields/video-field.d.ts +4 -0
- package/dist/silke/src/components/silke-link/silke-link.d.ts +1 -0
- package/dist/silke/src/components/silke-navigation-link/silke-navigation-link.d.ts +6 -1
- package/dist/silke/src/components/silke-text/silke-text.d.ts +1 -4
- package/dist/silke/src/components/silke-text-field/silke-text-field-outline.d.ts +3 -0
- package/dist/silke/src/hooks/drag-and-drop/use-drop.d.ts +2 -1
- package/dist/silke/src/icons.d.ts +8 -0
- package/dist/silke-code-editor-LK4ESGQO.js +25 -0
- package/dist/silke-code-editor-LK4ESGQO.js.map +7 -0
- package/dist/styles.css +1028 -926
- package/dist/utils/src/events/condition-parser/lexer.d.ts +1 -0
- package/dist/utils/src/types/context.d.ts +3 -1
- package/dist/utils/src/types/interaction.d.ts +9 -4
- package/dist/utils/src/types/vev-plugin.d.ts +40 -23
- package/dist/utils/src/types/vev-props.d.ts +6 -0
- package/dist/utils/src/utils/index.d.ts +1 -0
- package/dist/utils/src/utils/main-components.d.ts +7 -0
- package/esbuild.config.mjs +2 -4
- package/package.json +3 -3
- package/public/index.html +1 -1
- package/src/components/silke-autocomplete-field/silke-autocomplete-field.scss +13 -4
- package/src/components/silke-autocomplete-field/silke-autocomplete-field.tsx +32 -7
- package/src/components/silke-breadcrumbs/silke-breadcrumb.scss +11 -4
- package/src/components/silke-breadcrumbs/silke-breadcrumb.tsx +26 -6
- package/src/components/silke-button/index.ts +1 -0
- package/src/components/silke-button/silke-button.scss +0 -4
- package/src/components/silke-button/silke-button.tsx +8 -0
- package/src/components/silke-button/silke-dropdown-button.tsx +148 -0
- package/src/components/silke-color-picker/silke-color-picker.tsx +1 -0
- package/src/components/silke-color-swatches/silke-swatches.tsx +38 -6
- package/src/components/silke-context-menu/silke-context-menu.mdx +32 -0
- package/src/components/silke-context-menu/silke-context-menu.scss +6 -0
- package/src/components/silke-context-menu/silke-context-menu.tsx +22 -0
- package/src/components/silke-css-number-field/index.ts +1 -0
- package/src/components/silke-css-number-field/silke-css-context.tsx +17 -1
- package/src/components/silke-css-number-field/silke-css-number-field.mdx +30 -0
- package/src/components/silke-css-number-field/silke-css-number-field.scss +14 -2
- package/src/components/silke-css-number-field/silke-css-number-field.tsx +113 -13
- package/src/components/silke-css-number-field/variable-picker.tsx +181 -0
- package/src/components/silke-form-schema/fields/video-field.tsx +52 -0
- package/src/components/silke-form-schema/silke-schema-field.tsx +3 -1
- package/src/components/silke-image/silke-image.scss +1 -0
- package/src/components/silke-link/silke-link.mdx +3 -0
- package/src/components/silke-link/silke-link.scss +5 -1
- package/src/components/silke-link/silke-link.tsx +15 -3
- package/src/components/silke-modal/silke-modal.tsx +2 -0
- package/src/components/silke-navigation-link/silke-navigation-link.scss +67 -11
- package/src/components/silke-navigation-link/silke-navigation-link.tsx +171 -51
- package/src/components/silke-overflow-menu/silke-overflow-menu.scss +1 -1
- package/src/components/silke-overflow-menu/silke-overflow-menu.tsx +1 -1
- package/src/components/silke-select-field/silke-select-field.mdx +12 -0
- package/src/components/silke-text-field/silke-text-field-outline.tsx +69 -47
- package/src/components/silke-text-field/silke-text-field.scss +63 -0
- package/src/components/silke-text-field/silke-text-field.tsx +6 -0
- package/src/hooks/drag-and-drop/use-drop.tsx +3 -1
- package/src/icons.tsx +12 -2
- package/dist/silke-code-editor-4TSQ5KJ3.js +0 -25
- package/dist/silke-code-editor-4TSQ5KJ3.js.map +0 -7
- /package/dist/{silke-code-editor-4TSQ5KJ3.js.LEGAL.txt → silke-code-editor-LK4ESGQO.js.LEGAL.txt} +0 -0
|
@@ -88,6 +88,9 @@ export const SilkeTextField = React.forwardRef<HTMLDivElement, SilkeTextFieldPro
|
|
|
88
88
|
disabled,
|
|
89
89
|
readOnly,
|
|
90
90
|
tooltip,
|
|
91
|
+
showVariableDot,
|
|
92
|
+
hasActiveVariable,
|
|
93
|
+
onVariableClick,
|
|
91
94
|
...rest
|
|
92
95
|
} = useFormField(props, validateText);
|
|
93
96
|
|
|
@@ -147,6 +150,9 @@ export const SilkeTextField = React.forwardRef<HTMLDivElement, SilkeTextFieldPro
|
|
|
147
150
|
flex={flex}
|
|
148
151
|
disabled={disabled}
|
|
149
152
|
tooltip={tooltip}
|
|
153
|
+
showVariableDot={showVariableDot}
|
|
154
|
+
hasActiveVariable={hasActiveVariable}
|
|
155
|
+
onVariableClick={onVariableClick}
|
|
150
156
|
>
|
|
151
157
|
{before}
|
|
152
158
|
{React.createElement(multiline ? 'textarea' : 'input', {
|
|
@@ -9,11 +9,13 @@ export function useDrop<T>({
|
|
|
9
9
|
onOver,
|
|
10
10
|
onDrop,
|
|
11
11
|
canDrop,
|
|
12
|
+
disabled,
|
|
12
13
|
}: {
|
|
13
14
|
ref: MutableRefObject<HTMLElement | undefined | null>;
|
|
14
15
|
onOver?: (item: T, e: DragEvent) => void;
|
|
15
16
|
onDrop?: (item: T, e: DragEvent) => void;
|
|
16
17
|
canDrop?: (item: T, e: DragEvent, state: SilkeDropState) => boolean;
|
|
18
|
+
disabled?: boolean;
|
|
17
19
|
}): SilkeDropState {
|
|
18
20
|
const [state, setState] = useState<SilkeDropState>('none');
|
|
19
21
|
const stateRef = useRef<SilkeDropState>(state);
|
|
@@ -24,7 +26,7 @@ export function useDrop<T>({
|
|
|
24
26
|
|
|
25
27
|
useEffect(() => {
|
|
26
28
|
const el = ref.current;
|
|
27
|
-
if (el) {
|
|
29
|
+
if (el && !disabled) {
|
|
28
30
|
const handleDragEnter = (e: DragEvent) => {
|
|
29
31
|
(e.dataTransfer as any).dropEffect = 'move';
|
|
30
32
|
e.stopPropagation();
|
package/src/icons.tsx
CHANGED
|
@@ -22,7 +22,8 @@ export const SilkeIconDefinitions = {
|
|
|
22
22
|
share: 'fal fa-share-from-square',
|
|
23
23
|
'cloud.check': 'fal fa-cloud-check',
|
|
24
24
|
'cloud.slash': 'fal fa-cloud-slash',
|
|
25
|
-
|
|
25
|
+
ai: 'fa-light fa-sparkles',
|
|
26
|
+
compare: 'fal fa-shuffle',
|
|
26
27
|
menuMore: 'fal fa-ellipsis-v',
|
|
27
28
|
menu: 'fal fa-bars',
|
|
28
29
|
drag: 'fal fa-grip-lines',
|
|
@@ -39,7 +40,7 @@ export const SilkeIconDefinitions = {
|
|
|
39
40
|
rollback: 'fal fa-history',
|
|
40
41
|
settings: 'fal fa-cog',
|
|
41
42
|
search: 'fal fa-search',
|
|
42
|
-
library: 'fal fa-book',
|
|
43
|
+
library: 'fal fa-book-open',
|
|
43
44
|
'search.file': 'fal fa-file-magnifying-glass',
|
|
44
45
|
filter: 'fal fa-sliders-simple',
|
|
45
46
|
copy: 'fal fa-copy',
|
|
@@ -85,6 +86,9 @@ export const SilkeIconDefinitions = {
|
|
|
85
86
|
notification: 'fal fa-bell',
|
|
86
87
|
'notification.new': 'fal fa-bell-on',
|
|
87
88
|
|
|
89
|
+
tracking: 'fa-light fa-chart-line',
|
|
90
|
+
trackingEvent: 'fa-light fa-share-nodes',
|
|
91
|
+
|
|
88
92
|
package: 'fal fa-cube',
|
|
89
93
|
'package.open': 'fal fa-box-open',
|
|
90
94
|
'select.all': 'fal fa-check-double',
|
|
@@ -164,10 +168,12 @@ export const SilkeIconDefinitions = {
|
|
|
164
168
|
|
|
165
169
|
// PLATFORM ICONS
|
|
166
170
|
template: 'fal fa-copy',
|
|
171
|
+
templates: 'fal fa-copy',
|
|
167
172
|
page: 'fal fa-page',
|
|
168
173
|
project: 'fal fa-browser',
|
|
169
174
|
projects: 'fal fa-browsers',
|
|
170
175
|
draft: 'fal fa-file',
|
|
176
|
+
drafts: 'fal fa-file',
|
|
171
177
|
account: 'fal fa-building',
|
|
172
178
|
user: 'fal fa-user',
|
|
173
179
|
'user.add': 'fal fa-user-plus',
|
|
@@ -368,6 +374,10 @@ export const SilkeIconDefinitions = {
|
|
|
368
374
|
'interaction.mouse-enter': 'fa-regular fa-up-right',
|
|
369
375
|
'interaction.mouse-leave': 'fa-regular fa-down-left',
|
|
370
376
|
'interaction.timer': 'fa-regular fa-timer',
|
|
377
|
+
|
|
378
|
+
// Variables
|
|
379
|
+
'variable.icon': 'fa-light fa-sliders',
|
|
380
|
+
'variable.color': 'fa-light fa-palette',
|
|
371
381
|
};
|
|
372
382
|
|
|
373
383
|
function CustomComponentIcon({ className }: { className?: string }) {
|