@cntrl-site/components 1.0.63-alpha.1 → 1.0.64-alpha.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/MarqueeText/MarqueeText.d.ts +44 -0
- package/dist/Components/MarqueeText/MarqueeTextComponent.d.ts +47 -0
- package/dist/Components/Pretext/Pretext.d.ts +13 -0
- package/dist/Components/Pretext/PretextComponent.d.ts +1 -0
- package/dist/index.js +1466 -93
- package/dist/index.mjs +10846 -8632
- package/package.json +1 -1
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
import { CommonComponentProps } from '../props';
|
|
2
|
+
export declare const MarqueeText: ({ settings, content, isEditor, isPreviewMode }: MarqueeTextProps) => import("react/jsx-runtime").JSX.Element;
|
|
3
|
+
export type MarqueeTextItem = {
|
|
4
|
+
text: string;
|
|
5
|
+
image?: {
|
|
6
|
+
url?: string;
|
|
7
|
+
name?: string;
|
|
8
|
+
};
|
|
9
|
+
link?: string;
|
|
10
|
+
};
|
|
11
|
+
export type MarqueeTextSettings = {
|
|
12
|
+
speed: number;
|
|
13
|
+
direction: 'left' | 'right';
|
|
14
|
+
pauseOnHover: 'on' | 'off';
|
|
15
|
+
gap: number;
|
|
16
|
+
ribbonWidth?: number;
|
|
17
|
+
layoutType: 'straight' | 'curve';
|
|
18
|
+
curveAmplitude: number;
|
|
19
|
+
curveFrequency: number;
|
|
20
|
+
textFontFamily: string;
|
|
21
|
+
textFontSettings: {
|
|
22
|
+
fontWeight: number;
|
|
23
|
+
fontStyle: string;
|
|
24
|
+
};
|
|
25
|
+
textFontSize: number;
|
|
26
|
+
textLineHeight: number;
|
|
27
|
+
textLetterSpacing: number;
|
|
28
|
+
textWordSpacing: number;
|
|
29
|
+
textTextAppearance: {
|
|
30
|
+
textTransform: string;
|
|
31
|
+
textDecoration: string;
|
|
32
|
+
fontVariant: string;
|
|
33
|
+
};
|
|
34
|
+
textColor: string;
|
|
35
|
+
backgroundColor: string;
|
|
36
|
+
};
|
|
37
|
+
type MarqueeTextProps = {
|
|
38
|
+
settings: MarqueeTextSettings;
|
|
39
|
+
content?: MarqueeTextItem[];
|
|
40
|
+
isEditor?: boolean;
|
|
41
|
+
isPreviewMode?: boolean;
|
|
42
|
+
isEditMode?: boolean;
|
|
43
|
+
} & CommonComponentProps;
|
|
44
|
+
export {};
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
import { ComponentSchemaV1 } from '../../types/SchemaV1';
|
|
2
|
+
export declare const MarqueeTextComponent: {
|
|
3
|
+
element: ({ settings, content, isEditor, isPreviewMode }: {
|
|
4
|
+
settings: import('./MarqueeText').MarqueeTextSettings;
|
|
5
|
+
content?: import('./MarqueeText').MarqueeTextItem[];
|
|
6
|
+
isEditor?: boolean;
|
|
7
|
+
isPreviewMode?: boolean;
|
|
8
|
+
isEditMode?: boolean;
|
|
9
|
+
} & import('../props').CommonComponentProps) => import("react/jsx-runtime").JSX.Element;
|
|
10
|
+
id: string;
|
|
11
|
+
name: string;
|
|
12
|
+
category: string;
|
|
13
|
+
version: number;
|
|
14
|
+
defaultSize: {
|
|
15
|
+
d: {
|
|
16
|
+
width: string;
|
|
17
|
+
};
|
|
18
|
+
t: {
|
|
19
|
+
width: string;
|
|
20
|
+
};
|
|
21
|
+
m: {
|
|
22
|
+
width: string;
|
|
23
|
+
};
|
|
24
|
+
};
|
|
25
|
+
preview: {
|
|
26
|
+
type: "image";
|
|
27
|
+
url: string;
|
|
28
|
+
};
|
|
29
|
+
schema: ComponentSchemaV1;
|
|
30
|
+
sourceCode: string;
|
|
31
|
+
assetsPaths: {
|
|
32
|
+
content: {
|
|
33
|
+
path: string;
|
|
34
|
+
placeholderEnabled: boolean;
|
|
35
|
+
}[];
|
|
36
|
+
parameters: never[];
|
|
37
|
+
};
|
|
38
|
+
fontSettingsPaths: {
|
|
39
|
+
content: never[];
|
|
40
|
+
parameters: {
|
|
41
|
+
path: string;
|
|
42
|
+
}[];
|
|
43
|
+
};
|
|
44
|
+
fontRelations: {
|
|
45
|
+
textFontSettings: string;
|
|
46
|
+
};
|
|
47
|
+
};
|
|
@@ -82,6 +82,8 @@ export type VecContour = {
|
|
|
82
82
|
/** Vector editing always happens in this coordinate space, so a drag is 1:1. */
|
|
83
83
|
export declare const EDIT_VIEW_BOX = "0 0 100 100";
|
|
84
84
|
export declare function mapContours(contours: VecContour[], transform: (point: Pt) => Pt): VecContour[];
|
|
85
|
+
/** Uniform (or axis-independent) scale about `origin` — keeps proportions when sx === sy. */
|
|
86
|
+
export declare function scaleContours(contours: VecContour[], origin: Pt, scaleX: number, scaleY?: number): VecContour[];
|
|
85
87
|
/**
|
|
86
88
|
* SVG path string → editable contours. Every command is normalized to cubic
|
|
87
89
|
* nodes, so what comes back can be dragged around and written out again.
|
|
@@ -97,6 +99,17 @@ export declare function flattenContours(contours: VecContour[]): Ring[];
|
|
|
97
99
|
* it is thinned out and smoothed back, which lands within a hair of the original.
|
|
98
100
|
*/
|
|
99
101
|
export declare function ringsToContours(rings: Ring[]): VecContour[];
|
|
102
|
+
/** Turns a preset into the editable viewBox path the editor persists after a shape pick. */
|
|
103
|
+
export declare function settingsForEditablePreset(shape: ShapeId, aspect?: number, previous?: {
|
|
104
|
+
customPath?: string;
|
|
105
|
+
pathFit?: string;
|
|
106
|
+
pathViewBox?: string;
|
|
107
|
+
}): {
|
|
108
|
+
shape: 'custom';
|
|
109
|
+
customPath: string;
|
|
110
|
+
pathFit: 'viewbox';
|
|
111
|
+
pathViewBox: string;
|
|
112
|
+
};
|
|
100
113
|
export declare function moveNodeTo(contours: VecContour[], contourIndex: number, nodeIndex: number, point: Pt): VecContour[];
|
|
101
114
|
export declare function setNodeHandle(contours: VecContour[], contourIndex: number, nodeIndex: number, which: 'in' | 'out', point: Pt, mirror: boolean): VecContour[];
|
|
102
115
|
/** Pulls a handle back into its anchor, straightening that side of the node. */
|