@bluepic/embed 0.4.0-next.98 → 0.5.0
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/bluepic-embed.iife.js +402 -178
- package/dist/bluepic-embed.umd.js +402 -178
- package/dist/c-B4BAHWS4.cjs +1 -0
- package/dist/{c-Bz1-FJiA.js → c-C0DTNf68.js} +122 -63
- package/dist/components/AssetViewer/AssetViewer.vue.d.ts +71 -0
- package/dist/components/BxAudioPlayButton.vue.d.ts +24 -0
- package/dist/components/BxCard.vue.d.ts +35 -0
- package/dist/components/BxInput.vue.d.ts +7 -1
- package/dist/components/BxList.vue.d.ts +9 -0
- package/dist/components/BxListItem.vue.d.ts +13 -1
- package/dist/components/BxPopover.vue.d.ts +7 -0
- package/dist/components/BxPreviewLayer.vue.d.ts +18 -0
- package/dist/components/BxScrollbar.vue.d.ts +7 -0
- package/dist/components/BxSelect.vue.d.ts +16 -2
- package/dist/components/BxTable.vue.d.ts +109 -0
- package/dist/components/BxTabs.vue.d.ts +7 -0
- package/dist/components/BxWaveformThumb.vue.d.ts +27 -0
- package/dist/components/CollectionFieldPopup.vue.d.ts +4 -0
- package/dist/components/PopoverElement.vue.d.ts +10 -1
- package/dist/components/TemplateEditor/BatchCell.vue.d.ts +18 -0
- package/dist/components/TemplateEditor/BatchEditor.vue.d.ts +264 -0
- package/dist/components/TemplateEditor/BatchExportPopup.vue.d.ts +68 -0
- package/dist/components/TemplateEditor/BatchImportPopup.vue.d.ts +25 -0
- package/dist/components/TemplateEditor/BxLiveTemplate.vue.d.ts +8 -0
- package/dist/components/TemplateEditor/BxTemplateEditor.vue.d.ts +285 -16
- package/dist/components/TemplateEditor/FieldHintsLayer.vue.d.ts +86 -0
- package/dist/components/TemplateEditor/TemplateView.vue.d.ts +77 -2
- package/dist/components/User/UserInfo.vue.d.ts +12 -1
- package/dist/components/directives/usePopup.d.ts +5 -0
- package/dist/components/fields/Collection.vue.d.ts +3 -0
- package/dist/components/fields/Image.vue.d.ts +19 -5
- package/dist/components/fields/ImageEdit.vue.d.ts +6 -1
- package/dist/components/fields/Text.vue.d.ts +1 -1
- package/dist/cpp-BfO2fOQK.cjs +1 -0
- package/dist/{cpp-CH0U-pDu.js → cpp-DxGBPWa5.js} +60 -39
- package/dist/{css-DXX4BvrO.js → css-Cx1gP-zj.js} +13 -8
- package/dist/css-DTF39MN3.cjs +1 -0
- package/dist/embed/embed.d.ts +1024 -228
- package/dist/{go-BpetKc7b.cjs → go-By8nj0Vi.cjs} +1 -1
- package/dist/{go-CkZ9_bn0.js → go-C8VcBUsu.js} +7 -2
- package/dist/{index-CWm6zOv7.js → index-C99_zLhc.js} +9 -9
- package/dist/index-D8N6IfRw.cjs +1 -0
- package/dist/{java-BicX26Pg.js → java-BoRJOXvw.js} +48 -39
- package/dist/java-DFXAwvvK.cjs +1 -0
- package/dist/javascript-C2jY0XE6.cjs +1 -0
- package/dist/{javascript-BAHKs5qZ.js → javascript-CgRUYx2b.js} +1 -0
- package/dist/main.cjs +240 -162
- package/dist/main.d.ts +20 -0
- package/dist/main.mjs +79357 -68780
- package/dist/markdown-BmL9j9cU.cjs +1 -0
- package/dist/{markdown-ga2-2-T7.js → markdown-D19noYwn.js} +9 -10
- package/dist/markdown-it-5-ieF6Bh.js +3790 -0
- package/dist/markdown-it-CLB5Jta6.cjs +16 -0
- package/dist/postal-mime-Df-WB8Vq.js +3337 -0
- package/dist/postal-mime-_7WF5UBe.cjs +28 -0
- package/dist/{python-CymlFLB0.js → python-BBUuE3AY.js} +20 -15
- package/dist/python-Clt6L10q.cjs +1 -0
- package/dist/{rust-BocnJ3Ns.js → rust-DY-oA2gr.js} +40 -26
- package/dist/rust-_vvcEGSJ.cjs +1 -0
- package/dist/{scss-DybQU0yX.js → scss-BWo_aR1L.js} +6 -1
- package/dist/scss-ex7iHSUb.cjs +1 -0
- package/dist/style.css +1 -1
- package/dist/theme/bridge.d.ts +14 -0
- package/dist/theme/color.d.ts +80 -0
- package/dist/theme/css.d.ts +8 -0
- package/dist/theme/index.d.ts +19 -0
- package/dist/theme/legacy.d.ts +3 -0
- package/dist/theme/resolve.d.ts +10 -0
- package/dist/theme/tokens.d.ts +129 -0
- package/dist/theme/types-contract.d.ts +13 -0
- package/dist/theme.cjs +1 -0
- package/dist/theme.mjs +1313 -0
- package/dist/{typescript-BRD67TAB.js → typescript-BHqLHF13.js} +1 -0
- package/dist/typescript-DYRnLHqF.cjs +1 -0
- package/dist/util/analytics.d.ts +16 -0
- package/dist/util/assetAuth.d.ts +35 -0
- package/dist/util/audioPreview.d.ts +8 -0
- package/dist/util/batch/csv.d.ts +58 -0
- package/dist/util/batch/export.d.ts +92 -0
- package/dist/util/batch/fields.d.ts +22 -0
- package/dist/util/batch/parseCSV.d.ts +72 -0
- package/dist/util/batch/useBatchRows.d.ts +67 -0
- package/dist/util/cloneDeep.d.ts +5 -5
- package/dist/util/cloudflareImages.d.ts +8 -1
- package/dist/util/contextCapture.d.ts +19 -0
- package/dist/util/export.d.ts +65 -18
- package/dist/util/fieldHints/chipAction.d.ts +23 -0
- package/dist/util/fieldHints/fieldFocus.d.ts +81 -0
- package/dist/util/fieldHints/geometry.d.ts +52 -0
- package/dist/util/fieldHints/index.d.ts +20 -0
- package/dist/util/fieldHints/probe.d.ts +84 -0
- package/dist/util/fieldHints/resolve.d.ts +55 -0
- package/dist/util/fieldHints/textProbe.d.ts +71 -0
- package/dist/util/fieldHints/useCanvasTextEditing.d.ts +125 -0
- package/dist/util/fieldHints/useChipHighlight.d.ts +29 -0
- package/dist/util/fieldHints/useFieldHitboxes.d.ts +5601 -0
- package/dist/util/fieldHints/useHintReveal.d.ts +10 -0
- package/dist/util/fieldTree.d.ts +20 -0
- package/dist/util/fields.d.ts +1 -1
- package/dist/util/gallery.d.ts +78 -32
- package/dist/util/popoverArrow.d.ts +33 -0
- package/dist/util/popupHeaderTools.d.ts +26 -0
- package/dist/util/scrollPassthrough.d.ts +9 -0
- package/dist/util/useTheme.d.ts +36 -1
- package/dist/util/visualViewport.d.ts +47 -0
- package/dist/xlsx-BopDBbWb.js +24176 -0
- package/dist/xlsx-qn1xoUuv.cjs +105 -0
- package/dist/{xml-B7THKYqr.js → xml-Bse49fPV.js} +9 -16
- package/dist/{xml-CII3FKiI.cjs → xml-CVmug_x4.cjs} +1 -1
- package/package.json +18 -5
- package/dist/c-C_Sx7N-F.cjs +0 -1
- package/dist/cpp-CEORmSCT.cjs +0 -1
- package/dist/css-l--Pv1Vb.cjs +0 -1
- package/dist/index-DFXQWOGQ.cjs +0 -1
- package/dist/java-BIk0G-rH.cjs +0 -1
- package/dist/javascript-NPBda6fN.cjs +0 -1
- package/dist/markdown-BbPYOuo6.cjs +0 -1
- package/dist/python-B6_9AjJr.cjs +0 -1
- package/dist/rust-DKnYCg2f.cjs +0 -1
- package/dist/scss-C_iicH8I.cjs +0 -1
- package/dist/typescript-ro3bsRwC.cjs +0 -1
- package/dist/util/backgroundRemoval.d.ts +0 -51
|
@@ -0,0 +1,109 @@
|
|
|
1
|
+
import { VNode } from 'vue';
|
|
2
|
+
export interface BxTableColumn {
|
|
3
|
+
/** Identity only; the caller writes the cells. */
|
|
4
|
+
key: string;
|
|
5
|
+
label: string;
|
|
6
|
+
align?: 'left' | 'center' | 'right';
|
|
7
|
+
width?: string;
|
|
8
|
+
/** Header text for assistive tech only, e.g. an actions column. */
|
|
9
|
+
srOnlyLabel?: boolean;
|
|
10
|
+
/** Class(es) put on the header cell — the caller puts the same on its `<td>`s. */
|
|
11
|
+
class?: string;
|
|
12
|
+
/**
|
|
13
|
+
* Pin the column while the table scrolls sideways. Pinned columns must be
|
|
14
|
+
* the outermost ones (the first N / the last N); anything else is ignored.
|
|
15
|
+
*/
|
|
16
|
+
sticky?: 'left' | 'right';
|
|
17
|
+
}
|
|
18
|
+
/**
|
|
19
|
+
* A table's chrome: the scroll container, the border, the header, row hover,
|
|
20
|
+
* per-column alignment, pinned header/columns and row states.
|
|
21
|
+
*
|
|
22
|
+
* The BODY is a slot rather than a `rows` prop on purpose. Real tables wrap
|
|
23
|
+
* their rows — the studio's org list puts every `<tr>` inside a
|
|
24
|
+
* visibility-observer for infinite scroll — and a data-driven table cannot
|
|
25
|
+
* express that without growing a render-prop for the wrapper. So the caller
|
|
26
|
+
* keeps its `<tr>`s and this owns everything around them, which is the part
|
|
27
|
+
* that was being re-written per app.
|
|
28
|
+
*
|
|
29
|
+
* Alignment and pinning reach app-authored cells through custom properties
|
|
30
|
+
* rather than classes the caller would have to remember: each column publishes
|
|
31
|
+
* `--col-N-align` (and, when pinned, `--col-N-position/left/right/z`), and the
|
|
32
|
+
* static rules below read them. Twenty-four columns is the supported width.
|
|
33
|
+
*
|
|
34
|
+
* Row states are read off ATTRIBUTES on the caller's `<tr>`, so a table stays
|
|
35
|
+
* a table for assistive tech:
|
|
36
|
+
* - `aria-current="true"` → the ACTIVE row (themed inset ring)
|
|
37
|
+
* - `aria-selected="true"` → a SELECTED row (soft primary background)
|
|
38
|
+
*/
|
|
39
|
+
type __VLS_Props = {
|
|
40
|
+
columns?: BxTableColumn[];
|
|
41
|
+
/** Outer border, so the table can sit on the page unwrapped. */
|
|
42
|
+
bordered?: boolean;
|
|
43
|
+
/** Corner rounding, same scale as BxCard. */
|
|
44
|
+
radius?: 'none' | 'sm' | 'md' | 'lg';
|
|
45
|
+
/**
|
|
46
|
+
* `plain` is a table on the page's own ground. `card` puts it on a raised
|
|
47
|
+
* surface, for a table that reads as a block of its own rather than a
|
|
48
|
+
* region of the page. (Note this differs from BxList's `card`, where each
|
|
49
|
+
* ROW is a surface; a table's rows cannot be separated without breaking
|
|
50
|
+
* column alignment, which is the whole point of a table.)
|
|
51
|
+
*/
|
|
52
|
+
variant?: 'plain' | 'card';
|
|
53
|
+
/** Row highlight on hover. Off unless rows actually do something. */
|
|
54
|
+
hoverable?: boolean;
|
|
55
|
+
dense?: boolean;
|
|
56
|
+
/** Keep the header row visible while the body scrolls vertically. */
|
|
57
|
+
stickyHeader?: boolean;
|
|
58
|
+
/**
|
|
59
|
+
* Fill the parent (a flex column) and scroll INSIDE the wrapper in both
|
|
60
|
+
* axes, instead of growing with the rows. Momentum scrolling and contained
|
|
61
|
+
* overscroll come with it, so the page never scrolls sideways.
|
|
62
|
+
*/
|
|
63
|
+
fill?: boolean;
|
|
64
|
+
/** Cap the wrapper's height; the body scrolls beyond it. */
|
|
65
|
+
maxHeight?: string;
|
|
66
|
+
/**
|
|
67
|
+
* Pin the first `left` / last `right` columns while scrolling sideways.
|
|
68
|
+
* The per-column `sticky` field is the other way to say the same thing.
|
|
69
|
+
*/
|
|
70
|
+
stickyColumns?: {
|
|
71
|
+
left?: number;
|
|
72
|
+
right?: number;
|
|
73
|
+
};
|
|
74
|
+
};
|
|
75
|
+
type __VLS_Slots = {
|
|
76
|
+
default?: () => VNode[] | VNode;
|
|
77
|
+
/** Replaces a header cell's label; the column def and its index come along. */
|
|
78
|
+
'header-cell'?: (scope: {
|
|
79
|
+
column: BxTableColumn;
|
|
80
|
+
index: number;
|
|
81
|
+
}) => VNode[] | VNode;
|
|
82
|
+
};
|
|
83
|
+
declare const __VLS_component: import("vue").DefineComponent<__VLS_Props, {
|
|
84
|
+
/** The outer box — query rows from here (`scrollIntoView` finds the scroller itself). */
|
|
85
|
+
wrapperRef: import("vue").Ref<HTMLDivElement | undefined, HTMLDivElement | undefined>;
|
|
86
|
+
/** BxScrollbar's inner container: the element that actually scrolls. */
|
|
87
|
+
scrollEl: import("vue").ComputedRef<HTMLElement | undefined>;
|
|
88
|
+
}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {
|
|
89
|
+
fill: boolean;
|
|
90
|
+
bordered: boolean;
|
|
91
|
+
hoverable: boolean;
|
|
92
|
+
radius: "none" | "sm" | "md" | "lg";
|
|
93
|
+
maxHeight: string;
|
|
94
|
+
variant: "plain" | "card";
|
|
95
|
+
columns: BxTableColumn[];
|
|
96
|
+
dense: boolean;
|
|
97
|
+
stickyHeader: boolean;
|
|
98
|
+
stickyColumns: {
|
|
99
|
+
left?: number;
|
|
100
|
+
right?: number;
|
|
101
|
+
};
|
|
102
|
+
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
103
|
+
declare const _default: __VLS_WithSlots<typeof __VLS_component, __VLS_Slots>;
|
|
104
|
+
export default _default;
|
|
105
|
+
type __VLS_WithSlots<T, S> = T & {
|
|
106
|
+
new (): {
|
|
107
|
+
$slots: S;
|
|
108
|
+
};
|
|
109
|
+
};
|
|
@@ -4,6 +4,13 @@ type __VLS_Props = {
|
|
|
4
4
|
name: string;
|
|
5
5
|
label?: string;
|
|
6
6
|
icon?: () => VNode[] | VNode;
|
|
7
|
+
/**
|
|
8
|
+
* Rendered AFTER the label — a count, a status dot. Separate from `icon`
|
|
9
|
+
* because it trails the name rather than introducing it, and because a
|
|
10
|
+
* tab that carries a number wants that number to read as part of the tab
|
|
11
|
+
* rather than as a second word in its name.
|
|
12
|
+
*/
|
|
13
|
+
suffix?: () => VNode[] | VNode;
|
|
7
14
|
}[];
|
|
8
15
|
secondary?: boolean;
|
|
9
16
|
size?: 'tiny' | 'small' | 'medium' | 'large';
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The generated waveform of an audio asset, painted in the CURRENT THEME's ink.
|
|
3
|
+
*
|
|
4
|
+
* bx-files renders an audio thumbnail as white bars on transparency (see
|
|
5
|
+
* `audioToPng`), which is only half a decision: it makes the image take the
|
|
6
|
+
* card's background, but it also makes it INVISIBLE on any light surface —
|
|
7
|
+
* white bars on a white card. Since a portal's theme is the customer's choice
|
|
8
|
+
* and half the presets are light, "white" is not a colour a waveform can be.
|
|
9
|
+
*
|
|
10
|
+
* The fix is to stop treating the PNG as a picture and treat it as a SHAPE: its
|
|
11
|
+
* alpha channel is the waveform, so it is used as a mask over `currentColor`.
|
|
12
|
+
* The bars then inherit whatever ink the surrounding text uses, in every theme,
|
|
13
|
+
* with no second asset, no server round-trip and no re-render of files already
|
|
14
|
+
* uploaded.
|
|
15
|
+
*
|
|
16
|
+
* Lives in the embed, next to `BxAudioPlayButton`, for the same reason: the
|
|
17
|
+
* studio library and the portal show the same audio card, and a treatment that
|
|
18
|
+
* exists in only one of them is how the two drift apart.
|
|
19
|
+
*/
|
|
20
|
+
type __VLS_Props = {
|
|
21
|
+
/** URL of the generated waveform PNG (white-on-transparent). */
|
|
22
|
+
src: string;
|
|
23
|
+
/** Accessible name — normally the asset's title. */
|
|
24
|
+
alt?: string;
|
|
25
|
+
};
|
|
26
|
+
declare const _default: import("vue").DefineComponent<__VLS_Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
27
|
+
export default _default;
|
|
@@ -10,8 +10,12 @@ declare const _default: <T extends {
|
|
|
10
10
|
description?: string;
|
|
11
11
|
detailedDescription?: string;
|
|
12
12
|
bridge: FieldsBridge;
|
|
13
|
+
defaultObject?: T;
|
|
14
|
+
/** @deprecated old prop name for `defaultObject`. */
|
|
13
15
|
defaultValue?: T;
|
|
14
16
|
mobile?: boolean;
|
|
17
|
+
min?: number;
|
|
18
|
+
max?: number;
|
|
15
19
|
} & {
|
|
16
20
|
modelValue: T[];
|
|
17
21
|
}) & Partial<{}>> & import("vue").PublicProps;
|
|
@@ -12,12 +12,20 @@ type __VLS_Props = {
|
|
|
12
12
|
bxPopoverId: string;
|
|
13
13
|
noPointerEvents: boolean;
|
|
14
14
|
overflowVisible: boolean;
|
|
15
|
+
/**
|
|
16
|
+
* Let wheel/touch gestures that land beside the popover scroll the app
|
|
17
|
+
* behind it. Set for popovers opened WITHOUT a scrim — with one, freezing
|
|
18
|
+
* the page is the intended modal behaviour. See useScrollPassthrough.
|
|
19
|
+
*/
|
|
20
|
+
scrollPassthrough?: boolean;
|
|
15
21
|
capturedContext?: Record<string | symbol, any>;
|
|
16
22
|
popoverMaxHeight?: string;
|
|
17
23
|
};
|
|
18
|
-
declare var __VLS_1: {};
|
|
24
|
+
declare var __VLS_1: {}, __VLS_6: {};
|
|
19
25
|
type __VLS_Slots = {} & {
|
|
20
26
|
default?: (props: typeof __VLS_1) => any;
|
|
27
|
+
} & {
|
|
28
|
+
default?: (props: typeof __VLS_6) => any;
|
|
21
29
|
};
|
|
22
30
|
declare const __VLS_component: import("vue").DefineComponent<__VLS_Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
23
31
|
close: () => any;
|
|
@@ -33,6 +41,7 @@ declare const __VLS_component: import("vue").DefineComponent<__VLS_Props, {}, {}
|
|
|
33
41
|
capturedContext: Record<string | symbol, any>;
|
|
34
42
|
floatingPadding: number;
|
|
35
43
|
noPointerEvents: boolean;
|
|
44
|
+
scrollPassthrough: boolean;
|
|
36
45
|
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
37
46
|
declare const _default: __VLS_WithSlots<typeof __VLS_component, __VLS_Slots>;
|
|
38
47
|
export default _default;
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import type { BluepicField } from '@bluepic/types';
|
|
2
|
+
type __VLS_Props = {
|
|
3
|
+
field: BluepicField;
|
|
4
|
+
/** The row's data object — mutated in place. */
|
|
5
|
+
data: Record<string, unknown>;
|
|
6
|
+
labelId?: string;
|
|
7
|
+
/** Header bulk control: route every write through `onBulkUpdate` instead. */
|
|
8
|
+
bulk?: boolean;
|
|
9
|
+
onBulkUpdate?: (bindingKey: string, value: unknown) => void;
|
|
10
|
+
};
|
|
11
|
+
declare const _default: import("vue").DefineComponent<__VLS_Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
12
|
+
change: (bindingKey: string, value: unknown) => any;
|
|
13
|
+
activate: () => any;
|
|
14
|
+
}, string, import("vue").PublicProps, Readonly<__VLS_Props> & Readonly<{
|
|
15
|
+
onChange?: ((bindingKey: string, value: unknown) => any) | undefined;
|
|
16
|
+
onActivate?: (() => any) | undefined;
|
|
17
|
+
}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
18
|
+
export default _default;
|
|
@@ -0,0 +1,264 @@
|
|
|
1
|
+
import { nextTick } from 'vue';
|
|
2
|
+
import type { Template } from '@bluepic/types';
|
|
3
|
+
import { type BxTableColumn } from '../BxTable.vue';
|
|
4
|
+
import type { BatchRowsModel } from '../../util/batch/useBatchRows';
|
|
5
|
+
/**
|
|
6
|
+
* The batch editor: a BxTable with one row per dataset and one column per
|
|
7
|
+
* field. Owns nothing but the table chrome — the rows live in `batch`
|
|
8
|
+
* (`useBatchRows`, created by BxTemplateEditor so the live preview and the
|
|
9
|
+
* export share the same model).
|
|
10
|
+
*/
|
|
11
|
+
type __VLS_Props = {
|
|
12
|
+
serial?: Template.Serial;
|
|
13
|
+
batch: BatchRowsModel;
|
|
14
|
+
/** The editor's resolved layout. Mobile drops the card chrome and goes full-bleed. */
|
|
15
|
+
layout?: 'mobile' | 'desktop';
|
|
16
|
+
};
|
|
17
|
+
declare const _default: import("vue").DefineComponent<__VLS_Props, {
|
|
18
|
+
tableRef: import("vue").Ref<({
|
|
19
|
+
$: import("vue").ComponentInternalInstance;
|
|
20
|
+
$data: {};
|
|
21
|
+
$props: {
|
|
22
|
+
readonly columns?: BxTableColumn[] | undefined;
|
|
23
|
+
readonly bordered?: boolean | undefined;
|
|
24
|
+
readonly radius?: "none" | "sm" | "md" | "lg" | undefined;
|
|
25
|
+
readonly variant?: "plain" | "card" | undefined;
|
|
26
|
+
readonly hoverable?: boolean | undefined;
|
|
27
|
+
readonly dense?: boolean | undefined;
|
|
28
|
+
readonly stickyHeader?: boolean | undefined;
|
|
29
|
+
readonly fill?: boolean | undefined;
|
|
30
|
+
readonly maxHeight?: string | undefined;
|
|
31
|
+
readonly stickyColumns?: {
|
|
32
|
+
left?: number;
|
|
33
|
+
right?: number;
|
|
34
|
+
} | undefined;
|
|
35
|
+
} & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps;
|
|
36
|
+
$attrs: import("vue").Attrs;
|
|
37
|
+
$refs: {
|
|
38
|
+
[x: string]: unknown;
|
|
39
|
+
};
|
|
40
|
+
$slots: Readonly<{
|
|
41
|
+
[name: string]: import("vue").Slot<any> | undefined;
|
|
42
|
+
}>;
|
|
43
|
+
$root: import("vue").ComponentPublicInstance | null;
|
|
44
|
+
$parent: import("vue").ComponentPublicInstance | null;
|
|
45
|
+
$host: Element | null;
|
|
46
|
+
$emit: (event: string, ...args: any[]) => void;
|
|
47
|
+
$el: any;
|
|
48
|
+
$options: import("vue").ComponentOptionsBase<Readonly<{
|
|
49
|
+
columns?: BxTableColumn[];
|
|
50
|
+
bordered?: boolean;
|
|
51
|
+
radius?: "none" | "sm" | "md" | "lg";
|
|
52
|
+
variant?: "plain" | "card";
|
|
53
|
+
hoverable?: boolean;
|
|
54
|
+
dense?: boolean;
|
|
55
|
+
stickyHeader?: boolean;
|
|
56
|
+
fill?: boolean;
|
|
57
|
+
maxHeight?: string;
|
|
58
|
+
stickyColumns?: {
|
|
59
|
+
left?: number;
|
|
60
|
+
right?: number;
|
|
61
|
+
};
|
|
62
|
+
}> & Readonly<{}>, {
|
|
63
|
+
wrapperRef: import("vue").Ref<HTMLDivElement | undefined, HTMLDivElement | undefined>;
|
|
64
|
+
scrollEl: import("vue").ComputedRef<HTMLElement | undefined>;
|
|
65
|
+
}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, {
|
|
66
|
+
fill: boolean;
|
|
67
|
+
bordered: boolean;
|
|
68
|
+
hoverable: boolean;
|
|
69
|
+
radius: "none" | "sm" | "md" | "lg";
|
|
70
|
+
maxHeight: string;
|
|
71
|
+
variant: "plain" | "card";
|
|
72
|
+
columns: BxTableColumn[];
|
|
73
|
+
dense: boolean;
|
|
74
|
+
stickyHeader: boolean;
|
|
75
|
+
stickyColumns: {
|
|
76
|
+
left?: number;
|
|
77
|
+
right?: number;
|
|
78
|
+
};
|
|
79
|
+
}, {}, string, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, import("vue").ComponentProvideOptions> & {
|
|
80
|
+
beforeCreate?: (() => void) | (() => void)[];
|
|
81
|
+
created?: (() => void) | (() => void)[];
|
|
82
|
+
beforeMount?: (() => void) | (() => void)[];
|
|
83
|
+
mounted?: (() => void) | (() => void)[];
|
|
84
|
+
beforeUpdate?: (() => void) | (() => void)[];
|
|
85
|
+
updated?: (() => void) | (() => void)[];
|
|
86
|
+
activated?: (() => void) | (() => void)[];
|
|
87
|
+
deactivated?: (() => void) | (() => void)[];
|
|
88
|
+
beforeDestroy?: (() => void) | (() => void)[];
|
|
89
|
+
beforeUnmount?: (() => void) | (() => void)[];
|
|
90
|
+
destroyed?: (() => void) | (() => void)[];
|
|
91
|
+
unmounted?: (() => void) | (() => void)[];
|
|
92
|
+
renderTracked?: ((e: import("vue").DebuggerEvent) => void) | ((e: import("vue").DebuggerEvent) => void)[];
|
|
93
|
+
renderTriggered?: ((e: import("vue").DebuggerEvent) => void) | ((e: import("vue").DebuggerEvent) => void)[];
|
|
94
|
+
errorCaptured?: ((err: unknown, instance: import("vue").ComponentPublicInstance | null, info: string) => boolean | void) | ((err: unknown, instance: import("vue").ComponentPublicInstance | null, info: string) => boolean | void)[];
|
|
95
|
+
};
|
|
96
|
+
$forceUpdate: () => void;
|
|
97
|
+
$nextTick: typeof nextTick;
|
|
98
|
+
$watch<T extends string | ((...args: any) => any)>(source: T, cb: T extends (...args: any) => infer R ? (...args: [R, R, import("@vue/reactivity").OnCleanup]) => any : (...args: [any, any, import("@vue/reactivity").OnCleanup]) => any, options?: import("vue").WatchOptions): import("vue").WatchStopHandle;
|
|
99
|
+
} & Readonly<{
|
|
100
|
+
fill: boolean;
|
|
101
|
+
bordered: boolean;
|
|
102
|
+
hoverable: boolean;
|
|
103
|
+
radius: "none" | "sm" | "md" | "lg";
|
|
104
|
+
maxHeight: string;
|
|
105
|
+
variant: "plain" | "card";
|
|
106
|
+
columns: BxTableColumn[];
|
|
107
|
+
dense: boolean;
|
|
108
|
+
stickyHeader: boolean;
|
|
109
|
+
stickyColumns: {
|
|
110
|
+
left?: number;
|
|
111
|
+
right?: number;
|
|
112
|
+
};
|
|
113
|
+
}> & Omit<Readonly<{
|
|
114
|
+
columns?: BxTableColumn[];
|
|
115
|
+
bordered?: boolean;
|
|
116
|
+
radius?: "none" | "sm" | "md" | "lg";
|
|
117
|
+
variant?: "plain" | "card";
|
|
118
|
+
hoverable?: boolean;
|
|
119
|
+
dense?: boolean;
|
|
120
|
+
stickyHeader?: boolean;
|
|
121
|
+
fill?: boolean;
|
|
122
|
+
maxHeight?: string;
|
|
123
|
+
stickyColumns?: {
|
|
124
|
+
left?: number;
|
|
125
|
+
right?: number;
|
|
126
|
+
};
|
|
127
|
+
}> & Readonly<{}>, "wrapperRef" | ("fill" | "bordered" | "hoverable" | "radius" | "maxHeight" | "variant" | "columns" | "dense" | "stickyHeader" | "stickyColumns") | "scrollEl"> & {
|
|
128
|
+
wrapperRef: HTMLDivElement | undefined;
|
|
129
|
+
scrollEl: HTMLElement | undefined;
|
|
130
|
+
} & {} & import("vue").ComponentCustomProperties & {} & {
|
|
131
|
+
$slots: {
|
|
132
|
+
default?: () => import("vue").VNode[] | import("vue").VNode;
|
|
133
|
+
'header-cell'?: (scope: {
|
|
134
|
+
column: BxTableColumn;
|
|
135
|
+
index: number;
|
|
136
|
+
}) => import("vue").VNode[] | import("vue").VNode;
|
|
137
|
+
};
|
|
138
|
+
}) | undefined, ({
|
|
139
|
+
$: import("vue").ComponentInternalInstance;
|
|
140
|
+
$data: {};
|
|
141
|
+
$props: {
|
|
142
|
+
readonly columns?: BxTableColumn[] | undefined;
|
|
143
|
+
readonly bordered?: boolean | undefined;
|
|
144
|
+
readonly radius?: "none" | "sm" | "md" | "lg" | undefined;
|
|
145
|
+
readonly variant?: "plain" | "card" | undefined;
|
|
146
|
+
readonly hoverable?: boolean | undefined;
|
|
147
|
+
readonly dense?: boolean | undefined;
|
|
148
|
+
readonly stickyHeader?: boolean | undefined;
|
|
149
|
+
readonly fill?: boolean | undefined;
|
|
150
|
+
readonly maxHeight?: string | undefined;
|
|
151
|
+
readonly stickyColumns?: {
|
|
152
|
+
left?: number;
|
|
153
|
+
right?: number;
|
|
154
|
+
} | undefined;
|
|
155
|
+
} & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps;
|
|
156
|
+
$attrs: import("vue").Attrs;
|
|
157
|
+
$refs: {
|
|
158
|
+
[x: string]: unknown;
|
|
159
|
+
};
|
|
160
|
+
$slots: Readonly<{
|
|
161
|
+
[name: string]: import("vue").Slot<any> | undefined;
|
|
162
|
+
}>;
|
|
163
|
+
$root: import("vue").ComponentPublicInstance | null;
|
|
164
|
+
$parent: import("vue").ComponentPublicInstance | null;
|
|
165
|
+
$host: Element | null;
|
|
166
|
+
$emit: (event: string, ...args: any[]) => void;
|
|
167
|
+
$el: any;
|
|
168
|
+
$options: import("vue").ComponentOptionsBase<Readonly<{
|
|
169
|
+
columns?: BxTableColumn[];
|
|
170
|
+
bordered?: boolean;
|
|
171
|
+
radius?: "none" | "sm" | "md" | "lg";
|
|
172
|
+
variant?: "plain" | "card";
|
|
173
|
+
hoverable?: boolean;
|
|
174
|
+
dense?: boolean;
|
|
175
|
+
stickyHeader?: boolean;
|
|
176
|
+
fill?: boolean;
|
|
177
|
+
maxHeight?: string;
|
|
178
|
+
stickyColumns?: {
|
|
179
|
+
left?: number;
|
|
180
|
+
right?: number;
|
|
181
|
+
};
|
|
182
|
+
}> & Readonly<{}>, {
|
|
183
|
+
wrapperRef: import("vue").Ref<HTMLDivElement | undefined, HTMLDivElement | undefined>;
|
|
184
|
+
scrollEl: import("vue").ComputedRef<HTMLElement | undefined>;
|
|
185
|
+
}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, {
|
|
186
|
+
fill: boolean;
|
|
187
|
+
bordered: boolean;
|
|
188
|
+
hoverable: boolean;
|
|
189
|
+
radius: "none" | "sm" | "md" | "lg";
|
|
190
|
+
maxHeight: string;
|
|
191
|
+
variant: "plain" | "card";
|
|
192
|
+
columns: BxTableColumn[];
|
|
193
|
+
dense: boolean;
|
|
194
|
+
stickyHeader: boolean;
|
|
195
|
+
stickyColumns: {
|
|
196
|
+
left?: number;
|
|
197
|
+
right?: number;
|
|
198
|
+
};
|
|
199
|
+
}, {}, string, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, import("vue").ComponentProvideOptions> & {
|
|
200
|
+
beforeCreate?: (() => void) | (() => void)[];
|
|
201
|
+
created?: (() => void) | (() => void)[];
|
|
202
|
+
beforeMount?: (() => void) | (() => void)[];
|
|
203
|
+
mounted?: (() => void) | (() => void)[];
|
|
204
|
+
beforeUpdate?: (() => void) | (() => void)[];
|
|
205
|
+
updated?: (() => void) | (() => void)[];
|
|
206
|
+
activated?: (() => void) | (() => void)[];
|
|
207
|
+
deactivated?: (() => void) | (() => void)[];
|
|
208
|
+
beforeDestroy?: (() => void) | (() => void)[];
|
|
209
|
+
beforeUnmount?: (() => void) | (() => void)[];
|
|
210
|
+
destroyed?: (() => void) | (() => void)[];
|
|
211
|
+
unmounted?: (() => void) | (() => void)[];
|
|
212
|
+
renderTracked?: ((e: import("vue").DebuggerEvent) => void) | ((e: import("vue").DebuggerEvent) => void)[];
|
|
213
|
+
renderTriggered?: ((e: import("vue").DebuggerEvent) => void) | ((e: import("vue").DebuggerEvent) => void)[];
|
|
214
|
+
errorCaptured?: ((err: unknown, instance: import("vue").ComponentPublicInstance | null, info: string) => boolean | void) | ((err: unknown, instance: import("vue").ComponentPublicInstance | null, info: string) => boolean | void)[];
|
|
215
|
+
};
|
|
216
|
+
$forceUpdate: () => void;
|
|
217
|
+
$nextTick: typeof nextTick;
|
|
218
|
+
$watch<T extends string | ((...args: any) => any)>(source: T, cb: T extends (...args: any) => infer R ? (...args: [R, R, import("@vue/reactivity").OnCleanup]) => any : (...args: [any, any, import("@vue/reactivity").OnCleanup]) => any, options?: import("vue").WatchOptions): import("vue").WatchStopHandle;
|
|
219
|
+
} & Readonly<{
|
|
220
|
+
fill: boolean;
|
|
221
|
+
bordered: boolean;
|
|
222
|
+
hoverable: boolean;
|
|
223
|
+
radius: "none" | "sm" | "md" | "lg";
|
|
224
|
+
maxHeight: string;
|
|
225
|
+
variant: "plain" | "card";
|
|
226
|
+
columns: BxTableColumn[];
|
|
227
|
+
dense: boolean;
|
|
228
|
+
stickyHeader: boolean;
|
|
229
|
+
stickyColumns: {
|
|
230
|
+
left?: number;
|
|
231
|
+
right?: number;
|
|
232
|
+
};
|
|
233
|
+
}> & Omit<Readonly<{
|
|
234
|
+
columns?: BxTableColumn[];
|
|
235
|
+
bordered?: boolean;
|
|
236
|
+
radius?: "none" | "sm" | "md" | "lg";
|
|
237
|
+
variant?: "plain" | "card";
|
|
238
|
+
hoverable?: boolean;
|
|
239
|
+
dense?: boolean;
|
|
240
|
+
stickyHeader?: boolean;
|
|
241
|
+
fill?: boolean;
|
|
242
|
+
maxHeight?: string;
|
|
243
|
+
stickyColumns?: {
|
|
244
|
+
left?: number;
|
|
245
|
+
right?: number;
|
|
246
|
+
};
|
|
247
|
+
}> & Readonly<{}>, "wrapperRef" | ("fill" | "bordered" | "hoverable" | "radius" | "maxHeight" | "variant" | "columns" | "dense" | "stickyHeader" | "stickyColumns") | "scrollEl"> & {
|
|
248
|
+
wrapperRef: HTMLDivElement | undefined;
|
|
249
|
+
scrollEl: HTMLElement | undefined;
|
|
250
|
+
} & {} & import("vue").ComponentCustomProperties & {} & {
|
|
251
|
+
$slots: {
|
|
252
|
+
default?: () => import("vue").VNode[] | import("vue").VNode;
|
|
253
|
+
'header-cell'?: (scope: {
|
|
254
|
+
column: BxTableColumn;
|
|
255
|
+
index: number;
|
|
256
|
+
}) => import("vue").VNode[] | import("vue").VNode;
|
|
257
|
+
};
|
|
258
|
+
}) | undefined>;
|
|
259
|
+
}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
260
|
+
import: () => any;
|
|
261
|
+
}, string, import("vue").PublicProps, Readonly<__VLS_Props> & Readonly<{
|
|
262
|
+
onImport?: (() => any) | undefined;
|
|
263
|
+
}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
264
|
+
export default _default;
|
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
import type { BatchFileFormat, BatchNaming, BatchFailedRow } from '../../util/batch/export';
|
|
2
|
+
import type { BatchCsvFormat } from '../../util/batch/csv';
|
|
3
|
+
export type BatchExportKind = 'files' | 'csv';
|
|
4
|
+
export interface BatchExportRunOptions {
|
|
5
|
+
kind: BatchExportKind;
|
|
6
|
+
format: BatchFileFormat | BatchCsvFormat;
|
|
7
|
+
naming: BatchNaming;
|
|
8
|
+
delimiter: ',' | ';';
|
|
9
|
+
prewarm: boolean;
|
|
10
|
+
signal: AbortSignal;
|
|
11
|
+
onProgress: (progress: {
|
|
12
|
+
done: number;
|
|
13
|
+
total: number;
|
|
14
|
+
failed?: number;
|
|
15
|
+
current?: number;
|
|
16
|
+
}) => void;
|
|
17
|
+
}
|
|
18
|
+
export interface BatchExportRunResult {
|
|
19
|
+
/** What to hand out: the zip / single file, or the CSV. */
|
|
20
|
+
output?: {
|
|
21
|
+
blob: Blob;
|
|
22
|
+
fileName: string;
|
|
23
|
+
};
|
|
24
|
+
/** Files count (files export) — for the wording. */
|
|
25
|
+
fileCount?: number;
|
|
26
|
+
/** CSV rows whose render URL is over budget (1-based). */
|
|
27
|
+
overBudget?: number[];
|
|
28
|
+
/** Pre-warm outcome (CSV). */
|
|
29
|
+
prewarmed?: {
|
|
30
|
+
done: number;
|
|
31
|
+
failed: number;
|
|
32
|
+
};
|
|
33
|
+
/** Files export: rows that threw and are missing from `output` (0-based index). */
|
|
34
|
+
failedRows?: BatchFailedRow[];
|
|
35
|
+
cancelled?: boolean;
|
|
36
|
+
}
|
|
37
|
+
/**
|
|
38
|
+
* The batch export dialog: choose format + naming, see what it costs, run,
|
|
39
|
+
* download. The parent supplies `run` — this component only knows the shape
|
|
40
|
+
* of the choices and the progress, not how rendering works.
|
|
41
|
+
*/
|
|
42
|
+
type __VLS_Props = {
|
|
43
|
+
kind: BatchExportKind;
|
|
44
|
+
rowCount: number;
|
|
45
|
+
templateName: string;
|
|
46
|
+
isVideoTemplate: boolean;
|
|
47
|
+
/** Rows a video batch may contain (tier). */
|
|
48
|
+
videoBatchMaxSize: number;
|
|
49
|
+
/** Whether outputs are charged in this context (false = the output is watermarked, which is free). */
|
|
50
|
+
consumesCredits: boolean;
|
|
51
|
+
/** Text bindings usable as file names: label → binding key. */
|
|
52
|
+
namingBindings: {
|
|
53
|
+
label: string;
|
|
54
|
+
key: string;
|
|
55
|
+
}[];
|
|
56
|
+
run: (opts: BatchExportRunOptions) => Promise<BatchExportRunResult>;
|
|
57
|
+
};
|
|
58
|
+
declare function cancelRun(): void;
|
|
59
|
+
declare const _default: import("vue").DefineComponent<__VLS_Props, {
|
|
60
|
+
cancelRun: typeof cancelRun;
|
|
61
|
+
}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
62
|
+
cancel: () => any;
|
|
63
|
+
done: (result: BatchExportRunResult) => any;
|
|
64
|
+
}, string, import("vue").PublicProps, Readonly<__VLS_Props> & Readonly<{
|
|
65
|
+
onCancel?: (() => any) | undefined;
|
|
66
|
+
onDone?: ((result: BatchExportRunResult) => any) | undefined;
|
|
67
|
+
}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
68
|
+
export default _default;
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { type BatchColumnField } from '../../util/batch/fields';
|
|
2
|
+
/**
|
|
3
|
+
* Import rows into the batch: parse (delimiter + per-cell type inference from
|
|
4
|
+
* the studio's parseCSV), match columns to fields, convert per field type.
|
|
5
|
+
* Columns whose header IS a binding key are matched up front — that is what
|
|
6
|
+
* "Export as CSV" writes, so a round trip needs no clicking.
|
|
7
|
+
*/
|
|
8
|
+
type __VLS_Props = {
|
|
9
|
+
columns: BatchColumnField[];
|
|
10
|
+
currentRowCount: number;
|
|
11
|
+
};
|
|
12
|
+
declare const _default: import("vue").DefineComponent<__VLS_Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
13
|
+
cancel: () => any;
|
|
14
|
+
confirm: (payload: {
|
|
15
|
+
datasets: Record<string, unknown>[];
|
|
16
|
+
mode: "append" | "replace";
|
|
17
|
+
}) => any;
|
|
18
|
+
}, string, import("vue").PublicProps, Readonly<__VLS_Props> & Readonly<{
|
|
19
|
+
onCancel?: (() => any) | undefined;
|
|
20
|
+
onConfirm?: ((payload: {
|
|
21
|
+
datasets: Record<string, unknown>[];
|
|
22
|
+
mode: "append" | "replace";
|
|
23
|
+
}) => any) | undefined;
|
|
24
|
+
}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
25
|
+
export default _default;
|
|
@@ -11,6 +11,12 @@ type __VLS_Props = {
|
|
|
11
11
|
serialWidth?: number;
|
|
12
12
|
serialHeight?: number;
|
|
13
13
|
preview?: string;
|
|
14
|
+
/**
|
|
15
|
+
* An individually pre-populated render of this template (`image.bluepic.io
|
|
16
|
+
* ?role=preview`), layered over `preview` in the skeleton until the live
|
|
17
|
+
* sandbox itself is ready. Omit when nothing pre-populates this view.
|
|
18
|
+
*/
|
|
19
|
+
personalizedPreviewSrc?: string | null;
|
|
14
20
|
data?: {
|
|
15
21
|
[k: string]: unknown;
|
|
16
22
|
};
|
|
@@ -29,6 +35,7 @@ declare function render(options: {
|
|
|
29
35
|
watermark: boolean;
|
|
30
36
|
resultType: 'blob';
|
|
31
37
|
externalCanvas: HTMLCanvasElement | null;
|
|
38
|
+
svgLoadWaitDelay?: number;
|
|
32
39
|
}): Promise<Blob>;
|
|
33
40
|
declare function render(options: {
|
|
34
41
|
type: 'image/png' | 'image/jpeg' | 'image/jpge' | 'image/webp';
|
|
@@ -43,6 +50,7 @@ declare function render(options: {
|
|
|
43
50
|
watermark: boolean;
|
|
44
51
|
resultType: 'canvas';
|
|
45
52
|
externalCanvas: HTMLCanvasElement | null;
|
|
53
|
+
svgLoadWaitDelay?: number;
|
|
46
54
|
}): Promise<HTMLCanvasElement>;
|
|
47
55
|
declare const _default: import("vue").DefineComponent<__VLS_Props, {
|
|
48
56
|
render: typeof render;
|