@blokkli/editor 2.0.0-alpha.23 → 2.0.0-alpha.25
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/dist/module.json +1 -1
- package/dist/module.mjs +252 -92
- package/dist/runtime/blokkliPlugins/BlockIndicator/index.vue.d.ts +38 -0
- package/dist/runtime/blokkliPlugins/ContextMenu/index.vue +1 -1
- package/dist/runtime/blokkliPlugins/ContextMenu/index.vue.d.ts +15 -0
- package/dist/runtime/blokkliPlugins/DebugOverlay/index.vue.d.ts +6 -0
- package/dist/runtime/blokkliPlugins/ItemAction/index.vue.d.ts +28 -3
- package/dist/runtime/blokkliPlugins/Sidebar/Detached/index.vue +6 -4
- package/dist/runtime/blokkliPlugins/Sidebar/index.vue +11 -3
- package/dist/runtime/blokkliPlugins/Sidebar/index.vue.d.ts +138 -3
- package/dist/runtime/blokkliPlugins/ToolbarButton/index.vue +5 -1
- package/dist/runtime/blokkliPlugins/ToolbarButton/index.vue.d.ts +116 -0
- package/dist/runtime/blokkliPlugins/TourItem/index.vue +22 -13
- package/dist/runtime/blokkliPlugins/TourItem/index.vue.d.ts +22 -0
- package/dist/runtime/blokkliPlugins/ViewOption/index.vue.d.ts +98 -0
- package/dist/runtime/blokkliPlugins/index.d.ts +1 -3
- package/dist/runtime/blokkliPlugins/index.js +0 -4
- package/dist/runtime/components/Blocks/NotImplemented/index.vue +24 -0
- package/dist/runtime/components/Blocks/NotImplemented/index.vue.d.ts +6 -0
- package/dist/runtime/components/BlokkliEditable.vue.d.ts +11 -0
- package/dist/runtime/components/BlokkliItem.vue +16 -3
- package/dist/runtime/components/BlokkliItem.vue.d.ts +2 -0
- package/dist/runtime/components/BlokkliProvider.vue.d.ts +1 -1
- package/dist/runtime/components/Edit/Actions/ItemDropdown.vue +1 -1
- package/dist/runtime/components/Edit/Actions/index.vue +78 -73
- package/dist/runtime/components/Edit/AddListItem/index.vue +9 -35
- package/dist/runtime/components/Edit/AddListItem/index.vue.d.ts +6 -15
- package/dist/runtime/components/Edit/AppMenu/MenuButton.vue +39 -0
- package/dist/runtime/{blokkliPlugins/MenuButton/index.vue.d.ts → components/Edit/AppMenu/MenuButton.vue.d.ts} +0 -4
- package/dist/runtime/components/Edit/AppMenu/index.vue +62 -40
- package/dist/runtime/components/Edit/ArtboardTooltip/index.vue +6 -0
- package/dist/runtime/components/Edit/BlockProxy/index.vue +2 -2
- package/dist/runtime/components/Edit/BlokkliErrorBoundary.vue +3 -0
- package/dist/runtime/components/Edit/BlokkliRootErrorBoundary.vue +4 -1
- package/dist/runtime/components/Edit/Dialog/index.vue +33 -47
- package/dist/runtime/components/Edit/Dialog/index.vue.d.ts +2 -0
- package/dist/runtime/components/Edit/DraggableList.vue +12 -9
- package/dist/runtime/components/Edit/EditIndicator.vue +11 -4
- package/dist/runtime/components/Edit/EditProvider.vue +75 -55
- package/dist/runtime/components/Edit/EditProvider.vue.d.ts +1 -1
- package/dist/runtime/components/Edit/Features/AddList/Actions/Action.vue +53 -0
- package/dist/runtime/components/Edit/Features/AddList/Actions/Action.vue.d.ts +7 -0
- package/dist/runtime/components/Edit/Features/AddList/Actions/index.vue +41 -0
- package/dist/runtime/components/Edit/Features/AddList/Actions/index.vue.d.ts +5 -0
- package/dist/runtime/components/Edit/Features/AddList/Blocks/index.vue +13 -50
- package/dist/runtime/components/Edit/Features/AddList/Blocks/index.vue.d.ts +5 -0
- package/dist/runtime/components/Edit/Features/AddList/index.vue +76 -119
- package/dist/runtime/components/Edit/Features/Analyze/Icon.vue +85 -0
- package/dist/runtime/components/Edit/Features/Analyze/Icon.vue.d.ts +5 -0
- package/dist/runtime/components/Edit/Features/Analyze/Main.vue +288 -59
- package/dist/runtime/components/Edit/Features/Analyze/Main.vue.d.ts +8 -1
- package/dist/runtime/components/Edit/Features/Analyze/Renderer/fragment.glsl +25 -13
- package/dist/runtime/components/Edit/Features/Analyze/Renderer/index.vue +114 -52
- package/dist/runtime/components/Edit/Features/Analyze/Renderer/index.vue.d.ts +16 -2
- package/dist/runtime/components/Edit/Features/Analyze/Renderer/vertex.glsl +31 -11
- package/dist/runtime/components/Edit/Features/Analyze/Results/Results.vue +2 -0
- package/dist/runtime/components/Edit/Features/Analyze/Results/Results.vue.d.ts +8 -1
- package/dist/runtime/components/Edit/Features/Analyze/Results/ResultsItem.vue +4 -4
- package/dist/runtime/components/Edit/Features/Analyze/Results/ResultsItem.vue.d.ts +20 -2
- package/dist/runtime/components/Edit/Features/Analyze/Results/ResultsItemNodes.vue +11 -18
- package/dist/runtime/components/Edit/Features/Analyze/Results/ResultsItemNodes.vue.d.ts +10 -3
- package/dist/runtime/components/Edit/Features/Analyze/Results/ResultsItemNodesTarget.vue +46 -40
- package/dist/runtime/components/Edit/Features/Analyze/Results/ResultsItemNodesTarget.vue.d.ts +10 -4
- package/dist/runtime/components/Edit/Features/Analyze/Summary/Chart.vue +8 -4
- package/dist/runtime/components/Edit/Features/Analyze/analyzers/axe.js +1 -0
- package/dist/runtime/components/Edit/Features/Analyze/analyzers/helpers/Context.d.ts +4 -3
- package/dist/runtime/components/Edit/Features/Analyze/analyzers/helpers/Context.js +2 -1
- package/dist/runtime/components/Edit/Features/Analyze/analyzers/readability.js +61 -20
- package/dist/runtime/components/Edit/Features/Analyze/analyzers/types.d.ts +15 -1
- package/dist/runtime/components/Edit/Features/Analyze/index.vue +23 -2
- package/dist/runtime/components/Edit/Features/Artboard/Overview/index.vue +22 -8
- package/dist/runtime/components/Edit/Features/Artboard/Renderer.vue +42 -21
- package/dist/runtime/components/Edit/Features/Artboard/Scrollbar/index.vue +10 -4
- package/dist/runtime/components/Edit/Features/Assistant/Overlay/index.vue +2 -28
- package/dist/runtime/components/Edit/Features/Assistant/index.vue +18 -14
- package/dist/runtime/components/Edit/Features/BlockScheduler/Dialog/index.vue +11 -1
- package/dist/runtime/components/Edit/Features/BlockScheduler/index.vue +2 -2
- package/dist/runtime/components/Edit/Features/Clipboard/List/index.vue +1 -1
- package/dist/runtime/components/Edit/Features/Clipboard/index.vue +52 -18
- package/dist/runtime/components/Edit/Features/CommandPalette/Palette/Item/index.vue +0 -2
- package/dist/runtime/components/Edit/Features/CommandPalette/Palette/Item/index.vue.d.ts +6 -4
- package/dist/runtime/components/Edit/Features/CommandPalette/Palette/index.vue +77 -27
- package/dist/runtime/components/Edit/Features/CommandPalette/index.vue +7 -4
- package/dist/runtime/components/Edit/Features/Comments/index.vue +2 -2
- package/dist/runtime/components/Edit/Features/Debug/Main.vue.d.ts +1 -1
- package/dist/runtime/components/Edit/Features/Debug/Rects/index.vue +2 -2
- package/dist/runtime/components/Edit/Features/Debug/Section/Logging.vue.d.ts +1 -1
- package/dist/runtime/components/Edit/Features/DraggingOverlay/DragItems/DragItem.vue +113 -0
- package/dist/runtime/components/Edit/Features/DraggingOverlay/DragItems/DragItem.vue.d.ts +25 -0
- package/dist/runtime/components/Edit/Features/DraggingOverlay/DragItems/index.vue +8 -97
- package/dist/runtime/components/Edit/Features/DraggingOverlay/Renderer/fragment.glsl +2 -5
- package/dist/runtime/components/Edit/Features/DraggingOverlay/Renderer/index.vue +38 -5
- package/dist/runtime/components/Edit/Features/DraggingOverlay/Renderer/vertex.glsl +10 -1
- package/dist/runtime/components/Edit/Features/DraggingOverlay/index.vue +1 -2
- package/dist/runtime/components/Edit/Features/EditForm/Frame/index.vue +8 -2
- package/dist/runtime/components/Edit/Features/EditForm/index.vue +3 -9
- package/dist/runtime/components/Edit/Features/EditableField/Overlay/Plaintext/index.vue +1 -1
- package/dist/runtime/components/Edit/Features/EditableField/Overlay/index.vue +4 -3
- package/dist/runtime/components/Edit/Features/EditableField/index.vue +2 -2
- package/dist/runtime/components/Edit/Features/EditableMask/index.vue +1 -1
- package/dist/runtime/components/Edit/Features/EntityTitle/index.vue +7 -2
- package/dist/runtime/components/Edit/Features/Exit/index.vue +12 -9
- package/dist/runtime/components/Edit/Features/Fragments/index.vue +27 -31
- package/dist/runtime/components/Edit/Features/ImportExisting/Dialog/index.vue +1 -0
- package/dist/runtime/components/Edit/Features/ImportExisting/index.vue +25 -24
- package/dist/runtime/components/Edit/Features/Library/EditReusable/index.vue +4 -4
- package/dist/runtime/components/Edit/Features/Library/LibraryDialog/index.vue +9 -2
- package/dist/runtime/components/Edit/Features/Library/ReusableDialog/index.vue +13 -3
- package/dist/runtime/components/Edit/Features/Library/index.vue +26 -24
- package/dist/runtime/components/Edit/Features/MediaLibrary/Library/index.vue +3 -2
- package/dist/runtime/components/Edit/Features/MultiSelect/Renderer/index.vue +1 -3
- package/dist/runtime/components/Edit/Features/Options/Form/Item.vue.d.ts +1 -1
- package/dist/runtime/components/Edit/Features/PreviewGrant/index.vue +3 -1
- package/dist/runtime/components/Edit/Features/Publish/Dialog/index.vue +10 -0
- package/dist/runtime/components/Edit/Features/Publish/index.vue +17 -15
- package/dist/runtime/components/Edit/Features/ResponsivePreview/Frame/index.vue +3 -2
- package/dist/runtime/components/Edit/Features/ResponsivePreview/index.vue +3 -2
- package/dist/runtime/components/Edit/Features/Revert/index.vue +24 -18
- package/dist/runtime/components/Edit/Features/Search/Overlay/Results/Content/index.vue +8 -2
- package/dist/runtime/components/Edit/Features/Search/Overlay/Results/Page/index.vue +12 -2
- package/dist/runtime/components/Edit/Features/Search/Overlay/index.vue +11 -3
- package/dist/runtime/components/Edit/Features/Search/index.vue +1 -1
- package/dist/runtime/components/Edit/Features/Selection/AddButtons/Overlay/index.vue +128 -31
- package/dist/runtime/components/Edit/Features/Selection/AddButtons/Overlay/index.vue.d.ts +6 -6
- package/dist/runtime/components/Edit/Features/Selection/AddButtons/index.vue +3 -6
- package/dist/runtime/components/Edit/Features/Selection/Renderer/index.vue +1 -1
- package/dist/runtime/components/Edit/Features/Settings/Dialog/index.vue +1 -0
- package/dist/runtime/components/Edit/Features/Settings/index.vue +26 -18
- package/dist/runtime/components/Edit/Features/Structure/List/Field/index.vue +3 -3
- package/dist/runtime/components/Edit/Features/TouchActionBar/index.vue +2 -2
- package/dist/runtime/components/Edit/Features/Tour/Overlay/index.vue +3 -3
- package/dist/runtime/components/Edit/Features/Tour/Popup/index.vue +2 -2
- package/dist/runtime/components/Edit/Features/Tour/index.vue +12 -10
- package/dist/runtime/components/Edit/Features/Transform/Dialog/index.vue +7 -1
- package/dist/runtime/components/Edit/Features/Transform/index.vue +1 -1
- package/dist/runtime/components/Edit/Features/Translations/index.vue +18 -17
- package/dist/runtime/components/Edit/Form/Textarea/index.vue +1 -1
- package/dist/runtime/components/Edit/FormOverlay/index.vue +13 -4
- package/dist/runtime/components/Edit/Indicators/index.vue +1 -1
- package/dist/runtime/components/Edit/InfoBox/index.vue +3 -2
- package/dist/runtime/components/Edit/InfoBox/index.vue.d.ts +6 -1
- package/dist/runtime/components/Edit/ItemIconBox/index.vue +41 -0
- package/dist/runtime/components/Edit/{AddListItemIcon → ItemIconBox}/index.vue.d.ts +5 -5
- package/dist/runtime/components/Edit/Konami/Game/index.vue +0 -1
- package/dist/runtime/components/Edit/Konami/index.vue +3 -5
- package/dist/runtime/components/Edit/Messages/Item/index.vue +11 -2
- package/dist/runtime/components/Edit/Messages/index.vue +6 -1
- package/dist/runtime/components/Edit/Overlay/index.vue +70 -0
- package/dist/runtime/components/Edit/Overlay/index.vue.d.ts +2 -0
- package/dist/runtime/components/Edit/PreviewProvider.vue +3 -3
- package/dist/runtime/components/Edit/ScaleToFit/index.vue +4 -4
- package/dist/runtime/components/Edit/SystemRequirements/index.vue +36 -36
- package/dist/runtime/components/Edit/Toolbar/index.vue +47 -48
- package/dist/runtime/components/Edit/index.d.ts +2 -2
- package/dist/runtime/components/Edit/index.js +2 -2
- package/dist/runtime/composables/defineBlokkliFeature.d.ts +1 -1
- package/dist/runtime/composables/useBlokkli.d.ts +6 -1
- package/dist/runtime/composables/useBlokkli.js +4 -1
- package/dist/runtime/css/output.css +1 -1
- package/dist/runtime/helpers/composables/defineAddAction.d.ts +2 -0
- package/dist/runtime/helpers/composables/defineAddAction.js +10 -0
- package/dist/runtime/helpers/composables/defineElementStyle.d.ts +2 -0
- package/dist/runtime/helpers/composables/defineElementStyle.js +33 -0
- package/dist/runtime/helpers/composables/defineItemDropdownAction.d.ts +1 -1
- package/dist/runtime/helpers/composables/defineItemDropdownAction.js +2 -2
- package/dist/runtime/helpers/composables/defineMenuButton.d.ts +2 -0
- package/dist/runtime/helpers/composables/defineMenuButton.js +10 -0
- package/dist/runtime/helpers/composables/defineRenderer.d.ts +1 -1
- package/dist/runtime/helpers/composables/onBroadcastEvent.d.ts +1 -1
- package/dist/runtime/helpers/composables/useBlockRegistration.d.ts +1 -1
- package/dist/runtime/helpers/composables/useBlockRegistration.js +12 -1
- package/dist/runtime/helpers/composables/useDebugLogger.d.ts +1 -1
- package/dist/runtime/helpers/composables/useDialog.d.ts +3 -0
- package/dist/runtime/helpers/composables/useDialog.js +16 -0
- package/dist/runtime/helpers/composables/useFocusTrap.d.ts +52 -0
- package/dist/runtime/helpers/composables/useFocusTrap.js +59 -0
- package/dist/runtime/helpers/composables/useGlobalBlokkliObject.d.ts +1 -1
- package/dist/runtime/helpers/{useTransitionedValue.js → composables/useTransitionedValue.js} +1 -1
- package/dist/runtime/helpers/dropTargets/index.d.ts +1 -1
- package/dist/runtime/helpers/dropTargets/index.js +17 -3
- package/dist/runtime/helpers/imports/index.d.ts +2 -1
- package/dist/runtime/helpers/imports/index.js +10 -1
- package/dist/runtime/helpers/{animationProvider.d.ts → providers/animation.d.ts} +100 -7
- package/dist/runtime/helpers/{animationProvider.js → providers/animation.js} +21 -11
- package/dist/runtime/helpers/providers/blocks.d.ts +25 -3
- package/dist/runtime/helpers/providers/blocks.js +19 -0
- package/dist/runtime/helpers/providers/commands.d.ts +41 -0
- package/dist/runtime/helpers/{commandsProvider.js → providers/commands.js} +1 -1
- package/dist/runtime/helpers/providers/debug.d.ts +125 -0
- package/dist/runtime/helpers/{debugProvider.js → providers/debug.js} +2 -2
- package/dist/runtime/helpers/providers/definition.d.ts +87 -0
- package/dist/runtime/helpers/providers/directive.d.ts +88 -2
- package/dist/runtime/helpers/providers/directive.js +18 -2
- package/dist/runtime/helpers/providers/dom.d.ts +225 -0
- package/dist/runtime/helpers/{domProvider.js → providers/dom.js} +34 -76
- package/dist/runtime/helpers/providers/dropArea.d.ts +47 -0
- package/dist/runtime/helpers/{dropAreaProvider.js → providers/dropArea.js} +1 -1
- package/dist/runtime/helpers/providers/element.d.ts +58 -1
- package/dist/runtime/helpers/providers/features.d.ts +56 -0
- package/dist/runtime/helpers/{featuresProvider.js → providers/features.js} +1 -1
- package/dist/runtime/helpers/providers/fields.d.ts +19 -4
- package/dist/runtime/helpers/providers/fields.js +1 -1
- package/dist/runtime/helpers/providers/indicators.d.ts +44 -0
- package/dist/runtime/helpers/providers/keyboard.d.ts +76 -0
- package/dist/runtime/helpers/{keyboardProvider.js → providers/keyboard.js} +1 -8
- package/dist/runtime/helpers/providers/plugin.d.ts +81 -0
- package/dist/runtime/helpers/providers/plugin.js +64 -0
- package/dist/runtime/helpers/{selectionProvider.d.ts → providers/selection.d.ts} +4 -1
- package/dist/runtime/helpers/{selectionProvider.js → providers/selection.js} +1 -1
- package/dist/runtime/helpers/providers/state.d.ts +227 -0
- package/dist/runtime/helpers/{stateProvider.js → providers/state.js} +3 -3
- package/dist/runtime/helpers/providers/storage.d.ts +64 -0
- package/dist/runtime/helpers/{textProvider.d.ts → providers/texts.d.ts} +1 -1
- package/dist/runtime/helpers/providers/theme.d.ts +119 -0
- package/dist/runtime/helpers/{themeProvider.js → providers/theme.js} +3 -3
- package/dist/runtime/helpers/providers/tour.d.ts +49 -0
- package/dist/runtime/helpers/{tourProvider.js → providers/tour.js} +1 -1
- package/dist/runtime/helpers/providers/types.d.ts +170 -0
- package/dist/runtime/helpers/{typesProvider.js → providers/types.js} +45 -1
- package/dist/runtime/helpers/providers/ui.d.ts +339 -0
- package/dist/runtime/helpers/{uiProvider.js → providers/ui.js} +94 -86
- package/dist/runtime/helpers/runtimeHelpers/index.d.ts +1 -1
- package/dist/runtime/helpers/symbols.d.ts +1 -0
- package/dist/runtime/helpers/symbols.js +3 -0
- package/dist/runtime/icons/click.svg +1 -0
- package/dist/runtime/types/blockOptions.d.ts +349 -0
- package/dist/runtime/types/index.d.ts +34 -31
- package/package.json +2 -2
- package/dist/runtime/blokkliPlugins/AddAction/index.vue +0 -96
- package/dist/runtime/blokkliPlugins/AddAction/index.vue.d.ts +0 -26
- package/dist/runtime/blokkliPlugins/MenuButton/index.vue +0 -68
- package/dist/runtime/components/Edit/AddListItemIcon/index.vue +0 -19
- package/dist/runtime/helpers/commandsProvider.d.ts +0 -9
- package/dist/runtime/helpers/debugProvider.d.ts +0 -33
- package/dist/runtime/helpers/definitionProvider.d.ts +0 -19
- package/dist/runtime/helpers/domProvider.d.ts +0 -90
- package/dist/runtime/helpers/dropAreaProvider.d.ts +0 -9
- package/dist/runtime/helpers/featuresProvider.d.ts +0 -17
- package/dist/runtime/helpers/indicatorsProvider.d.ts +0 -10
- package/dist/runtime/helpers/keyboardProvider.d.ts +0 -20
- package/dist/runtime/helpers/pluginProvider.d.ts +0 -26
- package/dist/runtime/helpers/pluginProvider.js +0 -62
- package/dist/runtime/helpers/stateProvider.d.ts +0 -47
- package/dist/runtime/helpers/storageProvider.d.ts +0 -17
- package/dist/runtime/helpers/themeProvider.d.ts +0 -30
- package/dist/runtime/helpers/tourProvider.d.ts +0 -11
- package/dist/runtime/helpers/typesProvider.d.ts +0 -36
- package/dist/runtime/helpers/uiProvider.d.ts +0 -60
- package/dist/runtime/types/blokkOptions.d.ts +0 -100
- /package/dist/runtime/helpers/{addElementClasses.d.ts → composables/addElementClasses.d.ts} +0 -0
- /package/dist/runtime/helpers/{addElementClasses.js → composables/addElementClasses.js} +0 -0
- /package/dist/runtime/helpers/{useTransitionedValue.d.ts → composables/useTransitionedValue.d.ts} +0 -0
- /package/dist/runtime/helpers/{broadcastProvider.d.ts → providers/broadcast.d.ts} +0 -0
- /package/dist/runtime/helpers/{broadcastProvider.js → providers/broadcast.js} +0 -0
- /package/dist/runtime/helpers/{definitionProvider.js → providers/definition.js} +0 -0
- /package/dist/runtime/helpers/{indicatorsProvider.js → providers/indicators.js} +0 -0
- /package/dist/runtime/helpers/{storageProvider.js → providers/storage.js} +0 -0
- /package/dist/runtime/helpers/{textProvider.js → providers/texts.js} +0 -0
- /package/dist/runtime/types/{blokkOptions.js → blockOptions.js} +0 -0
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
<template>
|
|
2
|
-
<div
|
|
3
|
-
class="bk-list-item-icon"
|
|
4
|
-
:class="['bk-is-' + color, 'bk-is-' + orientation]"
|
|
5
|
-
>
|
|
6
|
-
<Icon v-if="icon" :name="icon" />
|
|
7
|
-
<ItemIcon v-else-if="bundle" :bundle="bundle" />
|
|
8
|
-
</div>
|
|
9
|
-
</template>
|
|
10
|
-
|
|
11
|
-
<script setup>
|
|
12
|
-
import { ItemIcon, Icon } from "#blokkli/components";
|
|
13
|
-
defineProps({
|
|
14
|
-
icon: { type: null, required: false, default: void 0 },
|
|
15
|
-
bundle: { type: String, required: false, default: void 0 },
|
|
16
|
-
color: { type: String, required: false, default: "default" },
|
|
17
|
-
orientation: { type: String, required: false, default: "horizontal" }
|
|
18
|
-
});
|
|
19
|
-
</script>
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import type { Command } from '#blokkli/types';
|
|
2
|
-
type CommandsProviderFunction = () => Command[] | Command | undefined;
|
|
3
|
-
export type CommandsProvider = {
|
|
4
|
-
add: (fn: CommandsProviderFunction) => void;
|
|
5
|
-
remove: (fn: CommandsProviderFunction) => void;
|
|
6
|
-
getCommands: () => Command[];
|
|
7
|
-
};
|
|
8
|
-
export default function (): CommandsProvider;
|
|
9
|
-
export {};
|
|
@@ -1,33 +0,0 @@
|
|
|
1
|
-
import type { StorageProvider } from './storageProvider.js';
|
|
2
|
-
import { type ComputedRef } from '#imports';
|
|
3
|
-
export type DebugLogger = {
|
|
4
|
-
log: (message: string, ...v: any) => void;
|
|
5
|
-
error: (message: string, ...v: any) => void;
|
|
6
|
-
};
|
|
7
|
-
export type LogMessage = {
|
|
8
|
-
type: 'log' | 'error' | 'event';
|
|
9
|
-
name: string;
|
|
10
|
-
date: string;
|
|
11
|
-
message: string;
|
|
12
|
-
context?: string;
|
|
13
|
-
};
|
|
14
|
-
type RegisteredDebugOverlay = {
|
|
15
|
-
id: string;
|
|
16
|
-
label: string;
|
|
17
|
-
active: boolean;
|
|
18
|
-
};
|
|
19
|
-
export type DebugProvider = {
|
|
20
|
-
isEnabled: ComputedRef<boolean>;
|
|
21
|
-
toggle: () => void;
|
|
22
|
-
createLogger: (name: string) => DebugLogger;
|
|
23
|
-
registerOverlay: (id: string, label: string) => void;
|
|
24
|
-
unregisterOverlay: (id: string) => void;
|
|
25
|
-
overlays: ComputedRef<RegisteredDebugOverlay[]>;
|
|
26
|
-
toggleOverlay: (id: string) => void;
|
|
27
|
-
registeredLoggers: ComputedRef<string[]>;
|
|
28
|
-
enabledLoggers: ComputedRef<string[]>;
|
|
29
|
-
toggleLogger: (name: string) => void;
|
|
30
|
-
getMessages: () => LogMessage[];
|
|
31
|
-
};
|
|
32
|
-
export default function (storage: StorageProvider): DebugProvider;
|
|
33
|
-
export {};
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
import { type Ref, type ComputedRef } from '#imports';
|
|
2
|
-
import type { BlockDefinition, FragmentDefinition, ProviderDefinition } from '#blokkli-build/definitions';
|
|
3
|
-
import type { ValidFieldListTypes, BlockBundleWithNested } from '#blokkli-build/generated-types';
|
|
4
|
-
import type { DeepReadonly } from 'vue';
|
|
5
|
-
import type { BlockDefinitionOptionsInput } from '../types/index.js';
|
|
6
|
-
import { type RuntimeBlockOptionArray } from '#blokkli-build/runtime-options';
|
|
7
|
-
export type DefinitionProvider = {
|
|
8
|
-
getBlockDefinition: (bundle: string, fieldListType: ValidFieldListTypes, parentBundle?: BlockBundleWithNested | null) => BlockDefinition | undefined;
|
|
9
|
-
getDefaultDefinition: (bundle: string) => BlockDefinition | undefined;
|
|
10
|
-
getFragmentDefinition: (name: string) => FragmentDefinition | undefined;
|
|
11
|
-
getProviderDefinition: (entityType: string, entityBundle: string) => ProviderDefinition | undefined;
|
|
12
|
-
getBlockIcon: (bundle: string) => string | undefined;
|
|
13
|
-
fragmentDefinitions: ComputedRef<FragmentDefinition[]>;
|
|
14
|
-
blockDefinitions: ComputedRef<BlockDefinition[]>;
|
|
15
|
-
globalOptions: DeepReadonly<Ref<BlockDefinitionOptionsInput>>;
|
|
16
|
-
runtimeOptions: DeepReadonly<Ref<Record<string, Record<string, RuntimeBlockOptionArray>>>>;
|
|
17
|
-
renderKey: DeepReadonly<Ref<string>>;
|
|
18
|
-
};
|
|
19
|
-
export default function (): DefinitionProvider;
|
|
@@ -1,90 +0,0 @@
|
|
|
1
|
-
import { type ComputedRef } from '#imports';
|
|
2
|
-
import type { DraggableExistingBlock, DraggableItem, EntityContext, Rectangle, RenderedFieldListItem, RegisteredField, RegisterFieldData } from '#blokkli/types';
|
|
3
|
-
import type { UiProvider } from './uiProvider.js';
|
|
4
|
-
import type { DebugProvider } from './debugProvider.js';
|
|
5
|
-
import type { DefinitionProvider } from './definitionProvider.js';
|
|
6
|
-
import type { StateProvider } from './stateProvider.js';
|
|
7
|
-
import type { ElementProvider } from './providers/element.js';
|
|
8
|
-
type RegisteredFieldType = {
|
|
9
|
-
entityType: string;
|
|
10
|
-
entityBundle: string;
|
|
11
|
-
fieldName: string;
|
|
12
|
-
};
|
|
13
|
-
type MeasuredBlockRect = Rectangle & {
|
|
14
|
-
time: number;
|
|
15
|
-
};
|
|
16
|
-
export type DomProvider = {
|
|
17
|
-
/**
|
|
18
|
-
* Return the droppable markup for a draggable item.
|
|
19
|
-
*/
|
|
20
|
-
getDropElementMarkup(item: DraggableItem | RenderedFieldListItem, checkSize?: boolean): string;
|
|
21
|
-
registerBlock: (key: string, uuid: string, el: HTMLElement | null) => void;
|
|
22
|
-
unregisterBlock: (key: string, uuid: string) => void;
|
|
23
|
-
registerField: (entity: EntityContext, fieldName: string, instance: HTMLElement, data: RegisterFieldData) => void;
|
|
24
|
-
updateFieldElement: (entity: EntityContext, fieldName: string, element: HTMLElement, data: RegisterFieldData) => void;
|
|
25
|
-
unregisterField: (entity: EntityContext, fieldName: string) => void;
|
|
26
|
-
getRegisteredField: (uuid: string, fieldName: string) => RegisteredField | undefined;
|
|
27
|
-
registeredFieldTypes: ComputedRef<RegisteredFieldType[]>;
|
|
28
|
-
registeredBlockUuids: ComputedRef<string[]>;
|
|
29
|
-
getVisibleBlocks(): string[];
|
|
30
|
-
getVisibleFields(): string[];
|
|
31
|
-
isBlockVisible(uuid: string): boolean;
|
|
32
|
-
getBlockRects: () => Record<string, MeasuredBlockRect>;
|
|
33
|
-
getBlockRect: (uuid: string, refresh?: boolean) => MeasuredBlockRect | undefined;
|
|
34
|
-
refreshBlockRect: (uuid: string) => void;
|
|
35
|
-
getFieldRect: (key: string) => Rectangle | undefined;
|
|
36
|
-
registeredBlocks: ComputedRef<Record<string, HTMLElement | undefined>>;
|
|
37
|
-
updateVisibleRects: () => void;
|
|
38
|
-
isReady: ComputedRef<boolean>;
|
|
39
|
-
init: () => void;
|
|
40
|
-
/**
|
|
41
|
-
* Get the drag element for a block.
|
|
42
|
-
*/
|
|
43
|
-
getDragElement: (block: DraggableExistingBlock | RenderedFieldListItem) => HTMLElement | undefined;
|
|
44
|
-
/**
|
|
45
|
-
* Get debug data for troubleshooting.
|
|
46
|
-
*/
|
|
47
|
-
getDebugData: () => {
|
|
48
|
-
registeredBlocks: Array<{
|
|
49
|
-
uuid: string;
|
|
50
|
-
hasElement: boolean;
|
|
51
|
-
hasObservedElement: boolean;
|
|
52
|
-
hasRect: boolean;
|
|
53
|
-
hasCurrentKey: boolean;
|
|
54
|
-
isVisible: boolean;
|
|
55
|
-
elementInfo?: {
|
|
56
|
-
tagName: string;
|
|
57
|
-
bundle?: string;
|
|
58
|
-
hostBundle?: string;
|
|
59
|
-
fieldListType?: string;
|
|
60
|
-
};
|
|
61
|
-
}>;
|
|
62
|
-
fields: Array<{
|
|
63
|
-
key: string;
|
|
64
|
-
isVisible: boolean;
|
|
65
|
-
hasRect: boolean;
|
|
66
|
-
entityType: string;
|
|
67
|
-
entityBundle: string;
|
|
68
|
-
fieldName: string;
|
|
69
|
-
}>;
|
|
70
|
-
summary: {
|
|
71
|
-
totalRegisteredBlocks: number;
|
|
72
|
-
totalBlocksWithElements: number;
|
|
73
|
-
totalObservedElements: number;
|
|
74
|
-
totalBlockRects: number;
|
|
75
|
-
totalVisibleBlocks: number;
|
|
76
|
-
totalRegisteredFields: number;
|
|
77
|
-
totalVisibleFields: number;
|
|
78
|
-
totalFieldRects: number;
|
|
79
|
-
isInitializing: boolean;
|
|
80
|
-
isReady: boolean;
|
|
81
|
-
};
|
|
82
|
-
orphanedData: {
|
|
83
|
-
rectsWithoutRegistration: string[];
|
|
84
|
-
observedElementsWithoutRegistration: string[];
|
|
85
|
-
keysWithoutRegistration: string[];
|
|
86
|
-
};
|
|
87
|
-
};
|
|
88
|
-
};
|
|
89
|
-
export default function (ui: UiProvider, debug: DebugProvider, definitions: DefinitionProvider, state: StateProvider, element: ElementProvider): DomProvider;
|
|
90
|
-
export {};
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import type { DraggableItem, DropArea } from '#blokkli/types';
|
|
2
|
-
type DropAreaProviderFunction = (items: DraggableItem[]) => DropArea[] | DropArea | undefined;
|
|
3
|
-
export type DropAreaProvider = {
|
|
4
|
-
add: (fn: DropAreaProviderFunction) => void;
|
|
5
|
-
remove: (fn: DropAreaProviderFunction) => void;
|
|
6
|
-
getDropAreas: (items: DraggableItem[]) => DropArea[];
|
|
7
|
-
};
|
|
8
|
-
export default function (): DropAreaProvider;
|
|
9
|
-
export {};
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
import type { FeatureDefinition, AdapterMethods } from '#blokkli/types';
|
|
2
|
-
import { type ValidFeatureKey } from '#blokkli-build/features';
|
|
3
|
-
import { type ComputedRef } from '#imports';
|
|
4
|
-
import type { StorageProvider } from './storageProvider.js';
|
|
5
|
-
export type FeaturesProvider = {
|
|
6
|
-
features: ComputedRef<FeatureDefinition[]>;
|
|
7
|
-
mountedFeatures: ComputedRef<FeatureDefinition<AdapterMethods[], ValidFeatureKey>[]>;
|
|
8
|
-
betaFeatures: ComputedRef<{
|
|
9
|
-
id: ValidFeatureKey;
|
|
10
|
-
label: string;
|
|
11
|
-
description?: string;
|
|
12
|
-
}[]>;
|
|
13
|
-
enabledBetaFeatures: ComputedRef<ValidFeatureKey[]>;
|
|
14
|
-
mount: (feature: FeatureDefinition<AdapterMethods[], ValidFeatureKey>) => void;
|
|
15
|
-
unmount: (id: string) => void;
|
|
16
|
-
};
|
|
17
|
-
export default function (storage: StorageProvider): FeaturesProvider;
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import { type Ref } from 'vue';
|
|
2
|
-
import type { BlockIndicator } from '../types/index.js';
|
|
3
|
-
export type IndicatorsProvider = {
|
|
4
|
-
indicators: Ref<BlockIndicator[]>;
|
|
5
|
-
hovered: Ref<string>;
|
|
6
|
-
addIndicator: (indicator: BlockIndicator) => void;
|
|
7
|
-
removeIndicator: (id: string, uuid: string) => void;
|
|
8
|
-
setHovered: (uuid?: string | null) => void;
|
|
9
|
-
};
|
|
10
|
-
export default function (): IndicatorsProvider;
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
import { type Ref, type ComputedRef } from 'vue';
|
|
2
|
-
import type { AnimationProvider } from './animationProvider.js';
|
|
3
|
-
import type { KeyboardShortcut } from '#blokkli/types';
|
|
4
|
-
type RegisteredShortcut = {
|
|
5
|
-
key: string;
|
|
6
|
-
shortcut: KeyboardShortcut;
|
|
7
|
-
};
|
|
8
|
-
export type KeyboardProvider = {
|
|
9
|
-
isPressingSpace: Readonly<Ref<boolean>>;
|
|
10
|
-
isPressingControl: Readonly<Ref<boolean>>;
|
|
11
|
-
isPressingShift: Readonly<Ref<boolean>>;
|
|
12
|
-
setShortcutStateFromEvent: (e: MouseEvent | PointerEvent) => void;
|
|
13
|
-
shortcuts: ComputedRef<RegisteredShortcut[]>;
|
|
14
|
-
registerShortcut: (shortcut: KeyboardShortcut) => void;
|
|
15
|
-
unregisterShortcut: (shortcut: KeyboardShortcut) => void;
|
|
16
|
-
lockKeyboardEvents: (id: string) => void;
|
|
17
|
-
unlockKeyboardEvents: (id: string) => void;
|
|
18
|
-
};
|
|
19
|
-
export default function (animationProvider: AnimationProvider): KeyboardProvider;
|
|
20
|
-
export {};
|
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
import type { AddAction } from '#blokkli/types';
|
|
2
|
-
import type { BlokkliIcon } from '#blokkli-build/icons';
|
|
3
|
-
type PluginAddFunction<T> = () => T | T[] | undefined;
|
|
4
|
-
type AddActionFunction = PluginAddFunction<AddAction>;
|
|
5
|
-
export type ItemDropdownAction = {
|
|
6
|
-
id: string;
|
|
7
|
-
label: string;
|
|
8
|
-
description?: string;
|
|
9
|
-
enabled?: boolean;
|
|
10
|
-
icon?: BlokkliIcon;
|
|
11
|
-
bundle?: string;
|
|
12
|
-
weight?: number;
|
|
13
|
-
group: string;
|
|
14
|
-
callback: () => void;
|
|
15
|
-
};
|
|
16
|
-
type ItemDropdownActionFunction = PluginAddFunction<ItemDropdownAction>;
|
|
17
|
-
export type PluginProvider = {
|
|
18
|
-
addAddAction: (fn: AddActionFunction) => void;
|
|
19
|
-
removeAddAction: (fn: AddActionFunction) => void;
|
|
20
|
-
getAddActions: () => AddAction[];
|
|
21
|
-
addItemDropdownAction: (fn: ItemDropdownActionFunction) => void;
|
|
22
|
-
removeItemDropdownAction: (fn: ItemDropdownActionFunction) => void;
|
|
23
|
-
getItemDropdownActions: () => ItemDropdownAction[];
|
|
24
|
-
};
|
|
25
|
-
export default function (): PluginProvider;
|
|
26
|
-
export {};
|
|
@@ -1,62 +0,0 @@
|
|
|
1
|
-
export default function() {
|
|
2
|
-
let addActions = [];
|
|
3
|
-
let itemDropdownActions = [];
|
|
4
|
-
function addAddAction(fn) {
|
|
5
|
-
addActions.push(fn);
|
|
6
|
-
}
|
|
7
|
-
function removeAddAction(fn) {
|
|
8
|
-
addActions = addActions.filter((v) => v !== fn);
|
|
9
|
-
}
|
|
10
|
-
function getAddActions() {
|
|
11
|
-
const actions = [];
|
|
12
|
-
for (let i = 0; i < addActions.length; i++) {
|
|
13
|
-
const callback = addActions[i];
|
|
14
|
-
if (!callback) {
|
|
15
|
-
continue;
|
|
16
|
-
}
|
|
17
|
-
const result = callback();
|
|
18
|
-
if (!result) {
|
|
19
|
-
continue;
|
|
20
|
-
}
|
|
21
|
-
if (Array.isArray(result)) {
|
|
22
|
-
actions.push(...result);
|
|
23
|
-
} else {
|
|
24
|
-
actions.push(result);
|
|
25
|
-
}
|
|
26
|
-
}
|
|
27
|
-
return actions;
|
|
28
|
-
}
|
|
29
|
-
function addItemDropdownAction(fn) {
|
|
30
|
-
itemDropdownActions.push(fn);
|
|
31
|
-
}
|
|
32
|
-
function removeItemDropdownAction(fn) {
|
|
33
|
-
itemDropdownActions = itemDropdownActions.filter((v) => v !== fn);
|
|
34
|
-
}
|
|
35
|
-
function getItemDropdownActions() {
|
|
36
|
-
const actions = [];
|
|
37
|
-
for (let i = 0; i < itemDropdownActions.length; i++) {
|
|
38
|
-
const callback = itemDropdownActions[i];
|
|
39
|
-
if (!callback) {
|
|
40
|
-
continue;
|
|
41
|
-
}
|
|
42
|
-
const result = callback();
|
|
43
|
-
if (!result) {
|
|
44
|
-
continue;
|
|
45
|
-
}
|
|
46
|
-
if (Array.isArray(result)) {
|
|
47
|
-
actions.push(...result);
|
|
48
|
-
} else {
|
|
49
|
-
actions.push(result);
|
|
50
|
-
}
|
|
51
|
-
}
|
|
52
|
-
return actions;
|
|
53
|
-
}
|
|
54
|
-
return {
|
|
55
|
-
addAddAction,
|
|
56
|
-
removeAddAction,
|
|
57
|
-
getAddActions,
|
|
58
|
-
addItemDropdownAction,
|
|
59
|
-
removeItemDropdownAction,
|
|
60
|
-
getItemDropdownActions
|
|
61
|
-
};
|
|
62
|
-
}
|
|
@@ -1,47 +0,0 @@
|
|
|
1
|
-
import { type Ref, type ComputedRef } from 'vue';
|
|
2
|
-
import type { BlokkliAdapter, AdapterContext } from '../adapter/index.js';
|
|
3
|
-
import type { MutatedField, EditEntity, MutatedOptions, TranslationState, MappedState, MutationItem, Validation, MutateWithLoadingStateFunction, EditMode, FieldListItem, PublishOptions, EditPermission } from '#blokkli/types';
|
|
4
|
-
import type { TextProvider } from './textProvider.js';
|
|
5
|
-
export type BlokkliOwner = {
|
|
6
|
-
name: string | undefined;
|
|
7
|
-
currentUserIsOwner: boolean;
|
|
8
|
-
};
|
|
9
|
-
export type RenderedBlock = {
|
|
10
|
-
item: FieldListItem;
|
|
11
|
-
parentEntityType: string;
|
|
12
|
-
parentEntityBundle: string;
|
|
13
|
-
parentEntityUuid: string;
|
|
14
|
-
};
|
|
15
|
-
export type StateProvider = {
|
|
16
|
-
owner: Readonly<Ref<BlokkliOwner | null>>;
|
|
17
|
-
refreshKey: Readonly<Ref<string>>;
|
|
18
|
-
mutatedFields: Readonly<Ref<MutatedField[]>>;
|
|
19
|
-
entity: Readonly<Ref<EditEntity>>;
|
|
20
|
-
mutatedOptions: MutatedOptions;
|
|
21
|
-
translation: Readonly<Ref<TranslationState>>;
|
|
22
|
-
publishOptions: Readonly<Ref<PublishOptions>>;
|
|
23
|
-
mutations: Readonly<Ref<MutationItem[]>>;
|
|
24
|
-
currentMutationIndex: Readonly<Ref<number>>;
|
|
25
|
-
violations: Readonly<Ref<Validation[]>>;
|
|
26
|
-
mutateWithLoadingState: MutateWithLoadingStateFunction;
|
|
27
|
-
editMode: Readonly<Ref<EditMode>>;
|
|
28
|
-
mutatedEntity: Readonly<Ref<any>>;
|
|
29
|
-
canEdit: ComputedRef<boolean>;
|
|
30
|
-
permissions: ComputedRef<EditPermission[]>;
|
|
31
|
-
stateAvailable: ComputedRef<boolean>;
|
|
32
|
-
isLoading: Readonly<Ref<boolean>>;
|
|
33
|
-
fromLibraryUuids: Readonly<Ref<Readonly<string[]>>>;
|
|
34
|
-
getFieldBlockCount: (key: string) => number;
|
|
35
|
-
getBlockBundleCount: (bundle: string) => number;
|
|
36
|
-
getFieldListItem: (uuid: string) => FieldListItem | undefined;
|
|
37
|
-
getFieldListForBlock: (uuid: string) => MutatedField | undefined;
|
|
38
|
-
getMutatedField: (uuid: string, fieldName: string) => MutatedField | undefined;
|
|
39
|
-
getAllUuids: (bundle?: string) => string[];
|
|
40
|
-
getNestingLevel: (uuid: string) => number;
|
|
41
|
-
isChildOf: (childUuid: string, parentUuid: string) => boolean;
|
|
42
|
-
getMappedState: () => MappedState;
|
|
43
|
-
setOverrideState: (state: MappedState) => void;
|
|
44
|
-
clearOverrideState: () => void;
|
|
45
|
-
getFieldKeyForUuid: (uuid: string) => string | null;
|
|
46
|
-
};
|
|
47
|
-
export default function (adapter: BlokkliAdapter<any>, context: ComputedRef<AdapterContext>, $t: TextProvider, providerKey: string, permissions: EditPermission[]): Promise<StateProvider>;
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
import { type ComputedRef, type WritableComputedRef } from '#imports';
|
|
2
|
-
import type { AdapterContext, BlokkliAdapter } from '#blokkli/adapter';
|
|
3
|
-
export type StorageProvider = {
|
|
4
|
-
use: <T>(key: string | ComputedRef<string>, defaultValue: T, persist?: boolean) => WritableComputedRef<T>;
|
|
5
|
-
useWithContextPrefix: <T>(key: string, defaultValue: T, persist?: boolean) => WritableComputedRef<T>;
|
|
6
|
-
clearAll: () => void;
|
|
7
|
-
clear: (key: string) => void;
|
|
8
|
-
};
|
|
9
|
-
/**
|
|
10
|
-
* Create a reactive variable that is synced to local storage using the
|
|
11
|
-
* given key. The sync only happens client side and after the component
|
|
12
|
-
* has been mounted.
|
|
13
|
-
*
|
|
14
|
-
* This composable can be used to keep state across page navigations and
|
|
15
|
-
* even after a refresh.
|
|
16
|
-
*/
|
|
17
|
-
export default function (adapter: BlokkliAdapter<any>, context: ComputedRef<AdapterContext>): Promise<StorageProvider>;
|
|
@@ -1,30 +0,0 @@
|
|
|
1
|
-
import type { DraggableStyle } from '#blokkli/types';
|
|
2
|
-
import type { RGB, ThemeColorGroup, ThemeColorShade, ThemeColors, ThemeContextColorGroup, ThemeContextColorShade, ThemeContextColors, ThemeName } from '#blokkli/types/theme';
|
|
3
|
-
import { type Ref } from '#imports';
|
|
4
|
-
import type { ElementProvider } from './providers/element.js';
|
|
5
|
-
type ThemeMap = {
|
|
6
|
-
accent: Ref<ThemeColors>;
|
|
7
|
-
mono: Ref<ThemeColors>;
|
|
8
|
-
teal: Ref<ThemeContextColors>;
|
|
9
|
-
yellow: Ref<ThemeContextColors>;
|
|
10
|
-
red: Ref<ThemeContextColors>;
|
|
11
|
-
lime: Ref<ThemeContextColors>;
|
|
12
|
-
orange: Ref<ThemeContextColors>;
|
|
13
|
-
};
|
|
14
|
-
export type ThemeProvider = {
|
|
15
|
-
accent: Ref<ThemeColors>;
|
|
16
|
-
mono: Ref<ThemeColors>;
|
|
17
|
-
teal: Ref<ThemeContextColors>;
|
|
18
|
-
yellow: Ref<ThemeContextColors>;
|
|
19
|
-
red: Ref<ThemeContextColors>;
|
|
20
|
-
lime: Ref<ThemeContextColors>;
|
|
21
|
-
orange: Ref<ThemeContextColors>;
|
|
22
|
-
getDraggableStyle: (el: HTMLElement | SVGElement) => DraggableStyle;
|
|
23
|
-
setColor: <Group extends ThemeColorGroup | ThemeContextColorGroup>(group: Group, shade: Group extends ThemeColorGroup ? ThemeColorShade : ThemeContextColorShade, value: RGB) => void;
|
|
24
|
-
applyTheme: (name: ThemeName | 'custom') => void;
|
|
25
|
-
invalidateCachedStyle: (el: HTMLElement | SVGElement) => void;
|
|
26
|
-
getColor<K extends keyof ThemeMap, T extends ThemeMap[K]['value']>(color: K, key: keyof T): RGB;
|
|
27
|
-
getColorString<K extends keyof ThemeMap, T extends ThemeMap[K]['value']>(color: K, key: keyof T, alpha?: number): string;
|
|
28
|
-
};
|
|
29
|
-
export default function (element: ElementProvider): ThemeProvider;
|
|
30
|
-
export {};
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import type { TourItem } from '#blokkli/types';
|
|
2
|
-
import { type Ref } from '#imports';
|
|
3
|
-
type TourProviderFunction = () => TourItem[] | TourItem | undefined;
|
|
4
|
-
export type TourProvider = {
|
|
5
|
-
add: (fn: TourProviderFunction) => void;
|
|
6
|
-
remove: (fn: TourProviderFunction) => void;
|
|
7
|
-
getTourItems: () => TourItem[];
|
|
8
|
-
isTouring: Ref<boolean>;
|
|
9
|
-
};
|
|
10
|
-
export default function (): TourProvider;
|
|
11
|
-
export {};
|
|
@@ -1,36 +0,0 @@
|
|
|
1
|
-
import type { ComputedRef } from 'vue';
|
|
2
|
-
import type { FieldConfig, BlockBundleDefinition, EditableFieldConfig, BlockDefinitionInput, BlockDefinitionOptionsInput, DroppableFieldConfig, DraggableExistingBlock, EntityContext } from '../types/index.js';
|
|
3
|
-
import type { AdapterContext, BlokkliAdapter } from '../adapter/index.js';
|
|
4
|
-
import type { SelectionProvider } from './selectionProvider.js';
|
|
5
|
-
export type BlokkliBlockType = BlockBundleDefinition & {
|
|
6
|
-
definition: BlockDefinitionInput<BlockDefinitionOptionsInput, never[]> | undefined;
|
|
7
|
-
};
|
|
8
|
-
interface MappableConfig {
|
|
9
|
-
entityType: string;
|
|
10
|
-
entityBundle: string;
|
|
11
|
-
name: string;
|
|
12
|
-
}
|
|
13
|
-
declare class ConfigMap<T extends MappableConfig> {
|
|
14
|
-
private configs;
|
|
15
|
-
private mapEntityType;
|
|
16
|
-
private mapEntityTypeBundle;
|
|
17
|
-
private mapEntityTypeBundleName;
|
|
18
|
-
constructor(items: T[]);
|
|
19
|
-
forEntityType(entityType: string): T[];
|
|
20
|
-
forEntityTypeAndBundle(entityType: string, entityBundle: string): T[];
|
|
21
|
-
forName(entityType: string, entityBundle: string, name: string): T | undefined;
|
|
22
|
-
all(): T[];
|
|
23
|
-
}
|
|
24
|
-
export type BlockDefinitionProvider = {
|
|
25
|
-
itemBundlesWithNested: string[];
|
|
26
|
-
allowedTypesInList: ComputedRef<string[]>;
|
|
27
|
-
generallyAvailableBundles: BlockBundleDefinition[];
|
|
28
|
-
getBlockBundleDefinition: (bundle: string) => BlockBundleDefinition | undefined;
|
|
29
|
-
getFieldConfig: (entityType: string, entityBundle: string, fieldName: string) => FieldConfig | undefined;
|
|
30
|
-
fieldConfig: ConfigMap<FieldConfig>;
|
|
31
|
-
editableFieldConfig: ConfigMap<EditableFieldConfig>;
|
|
32
|
-
droppableFieldConfig: ConfigMap<DroppableFieldConfig>;
|
|
33
|
-
getDroppableFieldConfig: (fieldName: string, host: DraggableExistingBlock | EntityContext) => DroppableFieldConfig;
|
|
34
|
-
};
|
|
35
|
-
export default function (adapter: BlokkliAdapter<any>, selection: SelectionProvider, context: ComputedRef<AdapterContext>): Promise<BlockDefinitionProvider>;
|
|
36
|
-
export {};
|
|
@@ -1,60 +0,0 @@
|
|
|
1
|
-
import { type Ref, type ComputedRef } from 'vue';
|
|
2
|
-
import type { StorageProvider } from './storageProvider.js';
|
|
3
|
-
import type { AddListOrientation, Coord, Rectangle, SidebarRegion, Size } from '#blokkli/types';
|
|
4
|
-
import type { Viewport } from '#blokkli/constants';
|
|
5
|
-
import type { StateProvider } from './stateProvider.js';
|
|
6
|
-
import type { AdapterContext } from '#blokkli/adapter';
|
|
7
|
-
import type { ThemeColorName } from '#blokkli/types/theme';
|
|
8
|
-
import type { ElementProvider } from './providers/element.js';
|
|
9
|
-
export type UiProvider = {
|
|
10
|
-
rootElement: () => HTMLElement;
|
|
11
|
-
artboardElement: () => HTMLElement;
|
|
12
|
-
providerElement: HTMLElement;
|
|
13
|
-
menu: {
|
|
14
|
-
isOpen: Readonly<Ref<boolean>>;
|
|
15
|
-
close: () => void;
|
|
16
|
-
open: () => void;
|
|
17
|
-
};
|
|
18
|
-
isMobile: ComputedRef<boolean>;
|
|
19
|
-
isDesktop: ComputedRef<boolean>;
|
|
20
|
-
isAnimating: Ref<boolean>;
|
|
21
|
-
isAnalyzing: Ref<boolean>;
|
|
22
|
-
isProxyMode: Ref<boolean>;
|
|
23
|
-
hasDialogOpen: Ref<boolean>;
|
|
24
|
-
hasTooltipOpen: ComputedRef<boolean>;
|
|
25
|
-
openTooltip: Ref<string>;
|
|
26
|
-
selectionColor: ComputedRef<ThemeColorName | null>;
|
|
27
|
-
setSelectionColor: (id: string, color: ThemeColorName) => void;
|
|
28
|
-
removeSelectionColor: (id: string) => void;
|
|
29
|
-
hasTransformOverlayOpen: Ref<boolean>;
|
|
30
|
-
isTransforming: ComputedRef<boolean>;
|
|
31
|
-
setTransform: (label?: string | null | undefined) => void;
|
|
32
|
-
transformLabel: ComputedRef<string>;
|
|
33
|
-
useAnimations: ComputedRef<boolean>;
|
|
34
|
-
lowPerformanceMode: ComputedRef<boolean>;
|
|
35
|
-
toolbarHeight: ComputedRef<number>;
|
|
36
|
-
visibleViewport: ComputedRef<Rectangle>;
|
|
37
|
-
visibleViewportPadded: ComputedRef<Rectangle>;
|
|
38
|
-
addListOrientation: ComputedRef<AddListOrientation>;
|
|
39
|
-
setViewportBlockingRectangle: (key: string, rect?: Rectangle) => void;
|
|
40
|
-
viewportBlockingRects: ComputedRef<Rectangle[]>;
|
|
41
|
-
appViewport: ComputedRef<Viewport>;
|
|
42
|
-
openContextMenu: Ref<string>;
|
|
43
|
-
viewport: ComputedRef<Size>;
|
|
44
|
-
artboardSize: ComputedRef<Size>;
|
|
45
|
-
artboardScale: Ref<number>;
|
|
46
|
-
artboardOffset: Ref<Coord>;
|
|
47
|
-
selectionTopLeft: Ref<Coord>;
|
|
48
|
-
interfaceLanguage: ComputedRef<string>;
|
|
49
|
-
locale: ComputedRef<string>;
|
|
50
|
-
formatDate: (date: string | Date, options?: Intl.DateTimeFormatOptions) => string;
|
|
51
|
-
getAbsoluteElementRect: (v: HTMLElement | Rectangle, scale?: number, offset?: Coord) => Rectangle;
|
|
52
|
-
getViewportRelativeRect: (rect: Rectangle, scale?: number, offset?: Coord) => Rectangle;
|
|
53
|
-
setBannerHeight: (id: string, height: number) => void;
|
|
54
|
-
removeBanner: (id: string) => void;
|
|
55
|
-
setActiveSidebar: (region: SidebarRegion, id: string) => void;
|
|
56
|
-
removeActiveSidebar: (region: SidebarRegion, id: string) => void;
|
|
57
|
-
hasSidebarLeft: ComputedRef<boolean>;
|
|
58
|
-
hasSidebarRight: ComputedRef<boolean>;
|
|
59
|
-
};
|
|
60
|
-
export default function (providerElement: HTMLElement, storage: StorageProvider, state: StateProvider, context: ComputedRef<AdapterContext>, element: ElementProvider): UiProvider;
|
|
@@ -1,100 +0,0 @@
|
|
|
1
|
-
import type { BlokkliIcon } from '#blokkli-build/icons';
|
|
2
|
-
type DefinitionOptionText = {
|
|
3
|
-
type: 'text';
|
|
4
|
-
default: string;
|
|
5
|
-
label: string;
|
|
6
|
-
description?: string;
|
|
7
|
-
inputType?: 'text' | 'number' | 'date';
|
|
8
|
-
group?: string;
|
|
9
|
-
};
|
|
10
|
-
type DefinitionOptionNumber = {
|
|
11
|
-
type: 'number';
|
|
12
|
-
default: number;
|
|
13
|
-
label: string;
|
|
14
|
-
description?: string;
|
|
15
|
-
min: number;
|
|
16
|
-
max: number;
|
|
17
|
-
group?: string;
|
|
18
|
-
};
|
|
19
|
-
type DefinitionOptionRange = {
|
|
20
|
-
type: 'range';
|
|
21
|
-
default: number;
|
|
22
|
-
label: string;
|
|
23
|
-
description?: string;
|
|
24
|
-
min: number;
|
|
25
|
-
max: number;
|
|
26
|
-
step: number;
|
|
27
|
-
group?: string;
|
|
28
|
-
};
|
|
29
|
-
type DefinitionOptionDateTimeLocal = {
|
|
30
|
-
type: 'datetime-local';
|
|
31
|
-
label: string;
|
|
32
|
-
description?: string;
|
|
33
|
-
default?: string;
|
|
34
|
-
min?: string;
|
|
35
|
-
max?: string;
|
|
36
|
-
group?: string;
|
|
37
|
-
};
|
|
38
|
-
type DefinitionOptionCheckbox = {
|
|
39
|
-
type: 'checkbox';
|
|
40
|
-
default: boolean;
|
|
41
|
-
label: string;
|
|
42
|
-
description?: string;
|
|
43
|
-
group?: string;
|
|
44
|
-
};
|
|
45
|
-
type DefinitionOptionColor = {
|
|
46
|
-
type: 'color';
|
|
47
|
-
default: `#${string}`;
|
|
48
|
-
label: string;
|
|
49
|
-
description?: string;
|
|
50
|
-
group?: string;
|
|
51
|
-
};
|
|
52
|
-
type DefinitionOptionCheckboxes = {
|
|
53
|
-
type: 'checkboxes';
|
|
54
|
-
label: string;
|
|
55
|
-
description?: string;
|
|
56
|
-
/**
|
|
57
|
-
* The default values.
|
|
58
|
-
*/
|
|
59
|
-
default: string[];
|
|
60
|
-
options: Record<string, string>;
|
|
61
|
-
group?: string;
|
|
62
|
-
};
|
|
63
|
-
type DefinitionOptionRadiosGridOption = {
|
|
64
|
-
columns: number[];
|
|
65
|
-
label: string;
|
|
66
|
-
};
|
|
67
|
-
type DefinitionOptionRadiosGrid = {
|
|
68
|
-
displayAs: 'grid';
|
|
69
|
-
options: Record<string, DefinitionOptionRadiosGridOption>;
|
|
70
|
-
};
|
|
71
|
-
type DefinitionOptionRadiosColorsOption = {
|
|
72
|
-
hex?: `#${string}`;
|
|
73
|
-
class?: string;
|
|
74
|
-
label: string;
|
|
75
|
-
};
|
|
76
|
-
type DefinitionOptionRadiosColors = {
|
|
77
|
-
displayAs: 'colors';
|
|
78
|
-
options: Record<string, DefinitionOptionRadiosColorsOption>;
|
|
79
|
-
};
|
|
80
|
-
type DefinitionOptionRadiosRadios = {
|
|
81
|
-
displayAs?: 'radios' | undefined;
|
|
82
|
-
options: Record<string, string>;
|
|
83
|
-
};
|
|
84
|
-
type DefinitionOptionRadiosIconsOption = {
|
|
85
|
-
icon: BlokkliIcon;
|
|
86
|
-
label: string;
|
|
87
|
-
};
|
|
88
|
-
type DefinitionOptionRadiosIcons = {
|
|
89
|
-
displayAs: 'icons';
|
|
90
|
-
options: Record<string, DefinitionOptionRadiosIconsOption>;
|
|
91
|
-
};
|
|
92
|
-
type DefinitionOptionRadios = {
|
|
93
|
-
type: 'radios';
|
|
94
|
-
label: string;
|
|
95
|
-
description?: string;
|
|
96
|
-
default: string;
|
|
97
|
-
group?: string;
|
|
98
|
-
} & (DefinitionOptionRadiosColors | DefinitionOptionRadiosGrid | DefinitionOptionRadiosRadios | DefinitionOptionRadiosIcons);
|
|
99
|
-
export type BlockOptionDefinition = DefinitionOptionColor | DefinitionOptionCheckbox | DefinitionOptionCheckboxes | DefinitionOptionRadios | DefinitionOptionText | DefinitionOptionRange | DefinitionOptionNumber | DefinitionOptionDateTimeLocal;
|
|
100
|
-
export {};
|
|
File without changes
|
|
File without changes
|
/package/dist/runtime/helpers/{useTransitionedValue.d.ts → composables/useTransitionedValue.d.ts}
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|