@salesql/sql_components_vue3 3.2.0 → 3.3.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/composables/useViewportClamp.d.ts +2 -2
- package/dist/constants/contact-data.d.ts +100 -0
- package/dist/constants/events.d.ts +8 -0
- package/dist/constants/pickers.d.ts +36 -0
- package/dist/index.cjs +1 -1
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.ts +21 -0
- package/dist/index.es.js +2321 -1315
- package/dist/index.es.js.map +1 -1
- package/dist/sql_components_vue3.css +1 -1
- package/dist/stories/StoryStage.vue.d.ts +12 -0
- package/dist/ui/DsAddToSequence/DsAddToSequence.types.d.ts +35 -0
- package/dist/ui/DsAddToSequence/DsAddToSequence.vue.d.ts +146 -0
- package/dist/ui/DsAddToSequence/index.d.ts +2 -0
- package/dist/ui/DsButton/DsButton.types.d.ts +1 -0
- package/dist/ui/DsButton/DsButton.vue.d.ts +3 -0
- package/dist/ui/DsContactCell/DsContactCell.types.d.ts +45 -0
- package/dist/ui/DsContactCell/DsContactCell.vue.d.ts +203 -0
- package/dist/ui/DsContactCell/index.d.ts +2 -0
- package/dist/ui/DsContactList/DsContactList.types.d.ts +26 -0
- package/dist/ui/DsContactList/DsContactList.vue.d.ts +139 -0
- package/dist/ui/DsContactList/index.d.ts +2 -0
- package/dist/ui/DsDeliverabilityBadge/DsDeliverabilityBadge.types.d.ts +13 -0
- package/dist/ui/DsDeliverabilityBadge/DsDeliverabilityBadge.vue.d.ts +41 -0
- package/dist/ui/DsDeliverabilityBadge/index.d.ts +2 -0
- package/dist/ui/DsMaskedValue/DsMaskedValue.types.d.ts +9 -0
- package/dist/ui/DsMaskedValue/DsMaskedValue.vue.d.ts +32 -0
- package/dist/ui/DsMaskedValue/index.d.ts +2 -0
- package/dist/ui/DsMoreCountChip/DsMoreCountChip.types.d.ts +8 -0
- package/dist/ui/DsMoreCountChip/DsMoreCountChip.vue.d.ts +31 -0
- package/dist/ui/DsMoreCountChip/index.d.ts +2 -0
- package/dist/ui/DsPopover/DsPopover.types.d.ts +15 -0
- package/dist/ui/DsPopover/DsPopover.vue.d.ts +18 -0
- package/dist/ui/DsSavedButton/DsSavedButton.types.d.ts +23 -0
- package/dist/ui/DsSavedButton/DsSavedButton.vue.d.ts +135 -0
- package/dist/ui/DsSavedButton/index.d.ts +2 -0
- package/dist/ui/DsTagPicker/DsTagPicker.types.d.ts +25 -0
- package/dist/ui/DsTagPicker/DsTagPicker.vue.d.ts +130 -0
- package/dist/ui/DsTagPicker/index.d.ts +2 -0
- package/llms-full.txt +523 -20
- package/llms.txt +8 -0
- package/package.json +1 -1
|
@@ -3,8 +3,8 @@ import { type Ref } from 'vue';
|
|
|
3
3
|
export declare const VIEWPORT_SHIFT_VAR = "--ds-overlay-shift";
|
|
4
4
|
/** Gap kept between the floating element and the viewport edge, in px. */
|
|
5
5
|
export declare const VIEWPORT_MARGIN = 8;
|
|
6
|
-
/** The side a floating element opens on. */
|
|
7
|
-
export type ClampSide = 'top' | 'bottom' | 'left' | 'right';
|
|
6
|
+
/** The side a floating element opens on. `over` (DsPopover) covers the trigger and aligns on X. */
|
|
7
|
+
export type ClampSide = 'top' | 'bottom' | 'left' | 'right' | 'over';
|
|
8
8
|
/**
|
|
9
9
|
* Placement vocabulary shared by the overlay family: a bare side (centred) or a
|
|
10
10
|
* `side-start` / `side-end` alignment. Only the SIDE matters here — it decides which
|
|
@@ -0,0 +1,100 @@
|
|
|
1
|
+
/** Which group an item came from. It is a property of the LIST, never of the item. */
|
|
2
|
+
export declare const DS_CONTACT_KINDS: {
|
|
3
|
+
readonly EMAIL: "email";
|
|
4
|
+
readonly PHONE: "phone";
|
|
5
|
+
};
|
|
6
|
+
export type DsContactKind = (typeof DS_CONTACT_KINDS)[keyof typeof DS_CONTACT_KINDS];
|
|
7
|
+
/**
|
|
8
|
+
* The contract's whole type vocabulary (§3.2: Work · Direct · Mobile · HQ · Other), keyed
|
|
9
|
+
* by the view model's own bucket values so a label and a bucket cannot drift apart. The
|
|
10
|
+
* visible LABEL for each is copy and arrives by prop; the type itself is a design key.
|
|
11
|
+
*/
|
|
12
|
+
export declare const DS_CONTACT_TYPES: {
|
|
13
|
+
readonly WORK: "work";
|
|
14
|
+
readonly DIRECT: "direct";
|
|
15
|
+
readonly MOBILE: "mobile";
|
|
16
|
+
readonly HQ: "hq";
|
|
17
|
+
readonly OTHER: "other";
|
|
18
|
+
};
|
|
19
|
+
export type DsContactType = (typeof DS_CONTACT_TYPES)[keyof typeof DS_CONTACT_TYPES];
|
|
20
|
+
/**
|
|
21
|
+
* In a contact-data row the type is an ICON on the left, not text (§3.2). These are the
|
|
22
|
+
* Material Symbols ligatures the design export assigns per type (`TYPE_META`); icons are
|
|
23
|
+
* design, so the mapping is the library's — the app never picks a glyph.
|
|
24
|
+
*/
|
|
25
|
+
export declare const DS_CONTACT_TYPE_ICONS: Readonly<Record<DsContactType, string>>;
|
|
26
|
+
/**
|
|
27
|
+
* The one item shape every DsContact* component reads. Deliberately the five facts a
|
|
28
|
+
* row needs and nothing else — the consuming app adapts its own view model to this
|
|
29
|
+
* (one line per field), so the library survives the app's model changing under it:
|
|
30
|
+
*
|
|
31
|
+
* legacy view model (§3.8) typed `contact_data` block (§3.11)
|
|
32
|
+
* id: item.id item.uid
|
|
33
|
+
* value: item.value item.is_revealed ? item.value : item.preview
|
|
34
|
+
* masked: item.isMasked !item.is_revealed
|
|
35
|
+
* valid: item.status === 'valid' item.verification === 'valid'
|
|
36
|
+
* primary: item.isPrimary item.is_primary
|
|
37
|
+
*
|
|
38
|
+
* A component never classifies, fetches or formats: `value` is rendered verbatim and
|
|
39
|
+
* `masked` decides only the two-tone rendering of a string the SERVER already masked.
|
|
40
|
+
*/
|
|
41
|
+
export interface DsContactItem {
|
|
42
|
+
/** Stable identity for keys and event payloads. `null` when the API sends none. */
|
|
43
|
+
id: string | number | null;
|
|
44
|
+
/** The string to display, already resolved by the consumer. Never re-formatted. */
|
|
45
|
+
value: string;
|
|
46
|
+
/** `true` when `value` is the server's masked preview. Reports; never hides. */
|
|
47
|
+
masked: boolean;
|
|
48
|
+
/** `true` only for a `valid` verdict — the sole state that renders the A+ badge. */
|
|
49
|
+
valid: boolean;
|
|
50
|
+
/** The group's primary. Rendered first; the cell shows it as the single value. */
|
|
51
|
+
primary: boolean;
|
|
52
|
+
/** The user's own rating of this item: correct / incorrect / unrated. */
|
|
53
|
+
rating?: boolean | null;
|
|
54
|
+
/**
|
|
55
|
+
* This row's own type, for lists that mix types (the unified Emails / Phones popovers).
|
|
56
|
+
* Sets the row glyph; a single-type list reads the list's `type` instead.
|
|
57
|
+
*/
|
|
58
|
+
type?: DsContactType;
|
|
59
|
+
}
|
|
60
|
+
/**
|
|
61
|
+
* One typed band of a unified list (export `DataPopover` subgroups): «WORK (2)» above its
|
|
62
|
+
* rows. The label is copy (the app's `TYPE_LABEL`); the type is the design key for the glyph.
|
|
63
|
+
*/
|
|
64
|
+
export interface DsContactSection {
|
|
65
|
+
type: DsContactType;
|
|
66
|
+
label: string;
|
|
67
|
+
items: DsContactItem[];
|
|
68
|
+
}
|
|
69
|
+
/**
|
|
70
|
+
* The three glyphs a server-masked value can be built from (contract §3.7 `MASK`):
|
|
71
|
+
* asterisks on the typed block's email `preview`, BULLET U+2022 on phones, and the
|
|
72
|
+
* ASCII dots the legacy arrays actually ship. Recognised, never produced.
|
|
73
|
+
*/
|
|
74
|
+
export declare const MASK_GLYPHS: readonly string[];
|
|
75
|
+
export interface DsMaskedSegment {
|
|
76
|
+
text: string;
|
|
77
|
+
/** Rendered in the mask tone (`$contact-data-mask-ink`) when true. */
|
|
78
|
+
masked: boolean;
|
|
79
|
+
}
|
|
80
|
+
/**
|
|
81
|
+
* The `+N` chip shows the OVERFLOW, not the group size (§3.5): `counts` in the view model
|
|
82
|
+
* are group sizes, so the consumer subtracts through this and `+0` never renders.
|
|
83
|
+
* Frozen as a function because three surfaces subtracting differently is exactly the
|
|
84
|
+
* divergence the contract exists to prevent.
|
|
85
|
+
*/
|
|
86
|
+
export declare function overflowFromGroupSize(groupSize: number): number;
|
|
87
|
+
/**
|
|
88
|
+
* Splits a string the server ALREADY masked into segments for the two-tone rendering
|
|
89
|
+
* (§3.7: «splitting an already-masked string leaks nothing»). The caller knows the value
|
|
90
|
+
* is masked — this never decides that, and never touches an unmasked value.
|
|
91
|
+
*
|
|
92
|
+
* - Email: the whole local part is the redaction, the domain stays visible (the quality
|
|
93
|
+
* signal). No `@` means the server masked the whole thing.
|
|
94
|
+
* - Phone: every run of mask glyphs is a redaction; a SINGLE dot is a real separator
|
|
95
|
+
* (`+1.415.555.0100`), so it stays visible. No prefix is assumed: `8008...` was
|
|
96
|
+
* measured with no `+` at all.
|
|
97
|
+
*
|
|
98
|
+
* Concatenating the segments always yields the input — nothing is re-grouped.
|
|
99
|
+
*/
|
|
100
|
+
export declare function splitMaskedValue(value: string, kind: DsContactKind): DsMaskedSegment[];
|
|
@@ -44,3 +44,11 @@ export declare const RESIZE_END: "resize-end";
|
|
|
44
44
|
export type ResizeEndEventName = typeof RESIZE_END;
|
|
45
45
|
export declare const UPDATE_OPEN: "update:open";
|
|
46
46
|
export type UpdateOpenEventName = typeof UPDATE_OPEN;
|
|
47
|
+
export declare const PICK: "pick";
|
|
48
|
+
export type PickEventName = typeof PICK;
|
|
49
|
+
export declare const APPLY: "apply";
|
|
50
|
+
export type ApplyEventName = typeof APPLY;
|
|
51
|
+
export declare const ADD: "add";
|
|
52
|
+
export type AddEventName = typeof ADD;
|
|
53
|
+
export declare const CREATE: "create";
|
|
54
|
+
export type CreateEventName = typeof CREATE;
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
import { type DsPopoverPlacement } from '@shared/ui/DsPopover';
|
|
2
|
+
/** One selectable thing: a folder, a tag, a campaign. `color` tints the row glyph / dot. */
|
|
3
|
+
export interface DsPickerOption {
|
|
4
|
+
id: string | number;
|
|
5
|
+
name: string;
|
|
6
|
+
color?: string;
|
|
7
|
+
}
|
|
8
|
+
/** Trigger height — `medium` for rows and the full profile, `large` for action / bulk bars. */
|
|
9
|
+
export declare const DS_PICKER_SIZES: {
|
|
10
|
+
readonly MEDIUM: "medium";
|
|
11
|
+
readonly LARGE: "large";
|
|
12
|
+
};
|
|
13
|
+
export type DsPickerSize = (typeof DS_PICKER_SIZES)[keyof typeof DS_PICKER_SIZES];
|
|
14
|
+
/** Which edge of the trigger the panel hangs from. */
|
|
15
|
+
export declare const DS_PICKER_ALIGNS: {
|
|
16
|
+
readonly START: "start";
|
|
17
|
+
readonly END: "end";
|
|
18
|
+
};
|
|
19
|
+
export type DsPickerAlign = (typeof DS_PICKER_ALIGNS)[keyof typeof DS_PICKER_ALIGNS];
|
|
20
|
+
/** The "send to" choice of Add to sequence — the contract's email kinds that can be mailed. */
|
|
21
|
+
export declare const DS_SEQUENCE_CHANNELS: {
|
|
22
|
+
readonly WORK: "work";
|
|
23
|
+
readonly DIRECT: "direct";
|
|
24
|
+
};
|
|
25
|
+
export type DsSequenceChannel = (typeof DS_SEQUENCE_CHANNELS)[keyof typeof DS_SEQUENCE_CHANNELS];
|
|
26
|
+
export interface DsSequenceChannelOption {
|
|
27
|
+
value: DsSequenceChannel;
|
|
28
|
+
/** Copy — the app passes it ("Work email"). */
|
|
29
|
+
label: string;
|
|
30
|
+
}
|
|
31
|
+
/** Case-insensitive, trimmed `includes` on `name`. An empty query keeps every option. */
|
|
32
|
+
export declare function filterOptions<T extends {
|
|
33
|
+
name: string;
|
|
34
|
+
}>(options: readonly T[], query: string): T[];
|
|
35
|
+
/** The panel opens below the trigger, aligned to the edge the consumer asked for. */
|
|
36
|
+
export declare function pickerPlacement(align: DsPickerAlign): DsPopoverPlacement;
|