@nexxtmove/ui 1.36.0 → 1.37.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/components/atoms/Icon/customIcons.d.ts +1 -1
- package/dist/components/editor/molecules/EditorLetterSpacing/EditorLetterSpacing.vue.d.ts +90 -0
- package/dist/components/editor/molecules/EditorLineHeight/EditorLineHeight.vue.d.ts +104 -0
- package/dist/index.d.ts +6 -0
- package/dist/index.js +869 -686
- package/dist/nuxt.js +2 -0
- package/package.json +1 -1
- package/src/components/editor/molecules/EditorLetterSpacing/EditorLetterSpacing.vue +163 -0
- package/src/components/editor/molecules/EditorLineHeight/EditorLineHeight.vue +161 -0
- package/src/components.json +2 -0
- package/src/env.d.ts +6 -1
- package/src/index.ts +12 -0
|
@@ -0,0 +1,90 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The steps the slider can land on, as the class they are stored as and the
|
|
3
|
+
* pixels that class is. Not a scale Tailwind has names for -- `tracking-wide`
|
|
4
|
+
* is an em and moves with the font size, and the editor shows every size in
|
|
5
|
+
* px -- so every step is an arbitrary-value class.
|
|
6
|
+
*
|
|
7
|
+
* The middle step is no class at all: zero is what the text already does, and
|
|
8
|
+
* storing nothing for it keeps the "no class means default" every other
|
|
9
|
+
* setting has. The negative side is there on purpose: tightening a large
|
|
10
|
+
* heading is a real need.
|
|
11
|
+
*
|
|
12
|
+
* The consumer stores these classes and lists them in an `@source inline` rule,
|
|
13
|
+
* so adding or renaming a token is a breaking change even though the component
|
|
14
|
+
* API stays the same.
|
|
15
|
+
*/
|
|
16
|
+
export declare const EDITOR_LETTER_SPACING_STEPS: readonly [{
|
|
17
|
+
readonly token: "tracking-[-1px]";
|
|
18
|
+
readonly px: -1;
|
|
19
|
+
}, {
|
|
20
|
+
readonly token: "tracking-[-0.5px]";
|
|
21
|
+
readonly px: -0.5;
|
|
22
|
+
}, {
|
|
23
|
+
readonly token: "tracking-[-0.25px]";
|
|
24
|
+
readonly px: -0.25;
|
|
25
|
+
}, {
|
|
26
|
+
readonly token: null;
|
|
27
|
+
readonly px: 0;
|
|
28
|
+
}, {
|
|
29
|
+
readonly token: "tracking-[0.25px]";
|
|
30
|
+
readonly px: 0.25;
|
|
31
|
+
}, {
|
|
32
|
+
readonly token: "tracking-[0.5px]";
|
|
33
|
+
readonly px: 0.5;
|
|
34
|
+
}, {
|
|
35
|
+
readonly token: "tracking-[1px]";
|
|
36
|
+
readonly px: 1;
|
|
37
|
+
}, {
|
|
38
|
+
readonly token: "tracking-[1.5px]";
|
|
39
|
+
readonly px: 1.5;
|
|
40
|
+
}, {
|
|
41
|
+
readonly token: "tracking-[2px]";
|
|
42
|
+
readonly px: 2;
|
|
43
|
+
}];
|
|
44
|
+
/**
|
|
45
|
+
* The letter spacing as the editor needs it: the Tailwind class itself, so the
|
|
46
|
+
* consumer can put the model value straight on the element it styles. The
|
|
47
|
+
* default step is `null` on the model, not a member of this type.
|
|
48
|
+
*/
|
|
49
|
+
export type EditorLetterSpacingValue = NonNullable<(typeof EDITOR_LETTER_SPACING_STEPS)[number]['token']>;
|
|
50
|
+
/** Overridable copy of the value readout. Every key is optional. */
|
|
51
|
+
export interface EditorLetterSpacingMessages {
|
|
52
|
+
/** Unit shown behind the value. Defaults to `'px'`. */
|
|
53
|
+
unit?: string;
|
|
54
|
+
/** Decimal separator of the readout. Defaults to the Dutch `','`. */
|
|
55
|
+
decimalSeparator?: string;
|
|
56
|
+
}
|
|
57
|
+
export interface NexxtEditorLetterSpacingProps {
|
|
58
|
+
/**
|
|
59
|
+
* Header text of the settings block. Defaults to the Dutch
|
|
60
|
+
* `'Letterafstand'`; the library has no i18n layer, so a consumer in another
|
|
61
|
+
* language passes its own copy in.
|
|
62
|
+
*/
|
|
63
|
+
label?: string;
|
|
64
|
+
/**
|
|
65
|
+
* Copy of the value readout. Merged per key, so overriding one key keeps the
|
|
66
|
+
* defaults of the others. Copy is never translated inside the component.
|
|
67
|
+
*/
|
|
68
|
+
messages?: EditorLetterSpacingMessages;
|
|
69
|
+
}
|
|
70
|
+
declare const _default: typeof __VLS_export;
|
|
71
|
+
export default _default;
|
|
72
|
+
declare const __VLS_export: import('vue').DefineComponent<NexxtEditorLetterSpacingProps & {
|
|
73
|
+
/**
|
|
74
|
+
* The selected letter spacing, as the Tailwind class to apply. `null` -- also
|
|
75
|
+
* what an unset model is -- is the default step: no class at all, zero.
|
|
76
|
+
*/
|
|
77
|
+
modelValue?: EditorLetterSpacingValue | null;
|
|
78
|
+
}, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
79
|
+
"update:modelValue": (value: EditorLetterSpacingValue | null) => any;
|
|
80
|
+
pointerup: (event: PointerEvent) => any;
|
|
81
|
+
}, string, import('vue').PublicProps, Readonly<NexxtEditorLetterSpacingProps & {
|
|
82
|
+
/**
|
|
83
|
+
* The selected letter spacing, as the Tailwind class to apply. `null` -- also
|
|
84
|
+
* what an unset model is -- is the default step: no class at all, zero.
|
|
85
|
+
*/
|
|
86
|
+
modelValue?: EditorLetterSpacingValue | null;
|
|
87
|
+
}> & Readonly<{
|
|
88
|
+
"onUpdate:modelValue"?: ((value: EditorLetterSpacingValue | null) => any) | undefined;
|
|
89
|
+
onPointerup?: ((event: PointerEvent) => any) | undefined;
|
|
90
|
+
}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
|
|
@@ -0,0 +1,104 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The steps the slider can land on, as the class they are stored as and the
|
|
3
|
+
* pixels that class is. The `leading-*` classes are Tailwind's spacing scale
|
|
4
|
+
* (calc of `--spacing`, 4px a step), so `leading-6` really is 24px -- and a
|
|
5
|
+
* line height set here does not scale with the font size; that is the deal the
|
|
6
|
+
* fixed steps make, and nothing here tries to compensate for it.
|
|
7
|
+
*
|
|
8
|
+
* The first step is no class at all: the element keeps its own line height.
|
|
9
|
+
* It has no px of its own, so the readout names it instead of measuring it.
|
|
10
|
+
*
|
|
11
|
+
* The consumer stores these classes and lists them in an `@source inline` rule,
|
|
12
|
+
* so adding or renaming a token is a breaking change even though the component
|
|
13
|
+
* API stays the same.
|
|
14
|
+
*/
|
|
15
|
+
export declare const EDITOR_LINE_HEIGHT_STEPS: readonly [{
|
|
16
|
+
readonly token: null;
|
|
17
|
+
readonly px: null;
|
|
18
|
+
}, {
|
|
19
|
+
readonly token: "leading-3";
|
|
20
|
+
readonly px: 12;
|
|
21
|
+
}, {
|
|
22
|
+
readonly token: "leading-4";
|
|
23
|
+
readonly px: 16;
|
|
24
|
+
}, {
|
|
25
|
+
readonly token: "leading-5";
|
|
26
|
+
readonly px: 20;
|
|
27
|
+
}, {
|
|
28
|
+
readonly token: "leading-6";
|
|
29
|
+
readonly px: 24;
|
|
30
|
+
}, {
|
|
31
|
+
readonly token: "leading-7";
|
|
32
|
+
readonly px: 28;
|
|
33
|
+
}, {
|
|
34
|
+
readonly token: "leading-8";
|
|
35
|
+
readonly px: 32;
|
|
36
|
+
}, {
|
|
37
|
+
readonly token: "leading-9";
|
|
38
|
+
readonly px: 36;
|
|
39
|
+
}, {
|
|
40
|
+
readonly token: "leading-10";
|
|
41
|
+
readonly px: 40;
|
|
42
|
+
}, {
|
|
43
|
+
readonly token: "leading-11";
|
|
44
|
+
readonly px: 44;
|
|
45
|
+
}, {
|
|
46
|
+
readonly token: "leading-12";
|
|
47
|
+
readonly px: 48;
|
|
48
|
+
}, {
|
|
49
|
+
readonly token: "leading-14";
|
|
50
|
+
readonly px: 56;
|
|
51
|
+
}, {
|
|
52
|
+
readonly token: "leading-16";
|
|
53
|
+
readonly px: 64;
|
|
54
|
+
}];
|
|
55
|
+
/**
|
|
56
|
+
* The line height as the editor needs it: the Tailwind class itself, so the
|
|
57
|
+
* consumer can put the model value straight on the element it styles. The
|
|
58
|
+
* default step is `null` on the model, not a member of this type.
|
|
59
|
+
*/
|
|
60
|
+
export type EditorLineHeightValue = NonNullable<(typeof EDITOR_LINE_HEIGHT_STEPS)[number]['token']>;
|
|
61
|
+
/** Overridable copy of the value readout. Every key is optional. */
|
|
62
|
+
export interface EditorLineHeightMessages {
|
|
63
|
+
/** Unit shown behind the value. Defaults to `'px'`. */
|
|
64
|
+
unit?: string;
|
|
65
|
+
/**
|
|
66
|
+
* Readout of the first step, no class, which has no px size. Defaults to
|
|
67
|
+
* the Dutch `'Standaard'`.
|
|
68
|
+
*/
|
|
69
|
+
default?: string;
|
|
70
|
+
}
|
|
71
|
+
export interface NexxtEditorLineHeightProps {
|
|
72
|
+
/**
|
|
73
|
+
* Header text of the settings block. Defaults to the Dutch
|
|
74
|
+
* `'Regelafstand'`; the library has no i18n layer, so a consumer in another
|
|
75
|
+
* language passes its own copy in.
|
|
76
|
+
*/
|
|
77
|
+
label?: string;
|
|
78
|
+
/**
|
|
79
|
+
* Copy of the value readout. Merged per key, so overriding one key keeps the
|
|
80
|
+
* defaults of the others. Copy is never translated inside the component.
|
|
81
|
+
*/
|
|
82
|
+
messages?: EditorLineHeightMessages;
|
|
83
|
+
}
|
|
84
|
+
declare const _default: typeof __VLS_export;
|
|
85
|
+
export default _default;
|
|
86
|
+
declare const __VLS_export: import('vue').DefineComponent<NexxtEditorLineHeightProps & {
|
|
87
|
+
/**
|
|
88
|
+
* The selected line height, as the Tailwind class to apply. `null` -- also
|
|
89
|
+
* what an unset model is -- is the default step: no class at all.
|
|
90
|
+
*/
|
|
91
|
+
modelValue?: EditorLineHeightValue | null;
|
|
92
|
+
}, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
93
|
+
"update:modelValue": (value: EditorLineHeightValue | null) => any;
|
|
94
|
+
pointerup: (event: PointerEvent) => any;
|
|
95
|
+
}, string, import('vue').PublicProps, Readonly<NexxtEditorLineHeightProps & {
|
|
96
|
+
/**
|
|
97
|
+
* The selected line height, as the Tailwind class to apply. `null` -- also
|
|
98
|
+
* what an unset model is -- is the default step: no class at all.
|
|
99
|
+
*/
|
|
100
|
+
modelValue?: EditorLineHeightValue | null;
|
|
101
|
+
}> & Readonly<{
|
|
102
|
+
"onUpdate:modelValue"?: ((value: EditorLineHeightValue | null) => any) | undefined;
|
|
103
|
+
onPointerup?: ((event: PointerEvent) => any) | undefined;
|
|
104
|
+
}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
|
package/dist/index.d.ts
CHANGED
|
@@ -23,6 +23,10 @@ export type { EditorTextAlignMessages, EditorTextAlignValue, } from './component
|
|
|
23
23
|
export type { EditorJustifyContentMessages, EditorJustifyContentValue, } from './components/editor/molecules/EditorJustifyContent/EditorJustifyContent.vue';
|
|
24
24
|
export { EDITOR_MAX_WIDTH_STEPS } from './components/editor/molecules/EditorMaxWidth/EditorMaxWidth.vue';
|
|
25
25
|
export type { EditorMaxWidthMessages, EditorMaxWidthValue, } from './components/editor/molecules/EditorMaxWidth/EditorMaxWidth.vue';
|
|
26
|
+
export { EDITOR_LINE_HEIGHT_STEPS } from './components/editor/molecules/EditorLineHeight/EditorLineHeight.vue';
|
|
27
|
+
export type { EditorLineHeightMessages, EditorLineHeightValue, } from './components/editor/molecules/EditorLineHeight/EditorLineHeight.vue';
|
|
28
|
+
export { EDITOR_LETTER_SPACING_STEPS } from './components/editor/molecules/EditorLetterSpacing/EditorLetterSpacing.vue';
|
|
29
|
+
export type { EditorLetterSpacingMessages, EditorLetterSpacingValue, } from './components/editor/molecules/EditorLetterSpacing/EditorLetterSpacing.vue';
|
|
26
30
|
export type { EditorPaddingMessages } from './components/editor/molecules/EditorPadding/EditorPadding.vue';
|
|
27
31
|
export type { NexxtTemplateCardContentFeature, NexxtTemplateCardProps, NexxtTemplateCardSlots, } from './components/molecules/TemplateCard/TemplateCard.vue';
|
|
28
32
|
export { default as NexxtAnimatedNumber } from './components/atoms/AnimatedNumber/AnimatedNumber.vue';
|
|
@@ -50,6 +54,8 @@ export { default as NexxtEditorFlexDirection } from './components/editor/molecul
|
|
|
50
54
|
export { default as NexxtEditorGap } from './components/editor/molecules/EditorGap/EditorGap.vue';
|
|
51
55
|
export { default as NexxtEditorHeadingType } from './components/editor/molecules/EditorHeadingType/EditorHeadingType.vue';
|
|
52
56
|
export { default as NexxtEditorJustifyContent } from './components/editor/molecules/EditorJustifyContent/EditorJustifyContent.vue';
|
|
57
|
+
export { default as NexxtEditorLetterSpacing } from './components/editor/molecules/EditorLetterSpacing/EditorLetterSpacing.vue';
|
|
58
|
+
export { default as NexxtEditorLineHeight } from './components/editor/molecules/EditorLineHeight/EditorLineHeight.vue';
|
|
53
59
|
export { default as NexxtEditorMaxWidth } from './components/editor/molecules/EditorMaxWidth/EditorMaxWidth.vue';
|
|
54
60
|
export { default as NexxtEditorPadding } from './components/editor/molecules/EditorPadding/EditorPadding.vue';
|
|
55
61
|
export { default as NexxtEditorRadius } from './components/editor/molecules/EditorRadius/EditorRadius.vue';
|