@ozguraltan/strapi-content-input 1.0.12 → 1.0.22
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/README.md +187 -54
- package/dist/admin/{AnalyticsHubPage-DNREITPq.js → AnalyticsHubPage-B1_chQkG.js} +60 -9
- package/dist/admin/{AnalyticsHubPage-Dj4roAe0.mjs → AnalyticsHubPage-DUj3D2kA.mjs} +60 -9
- package/dist/admin/{ContentInputField-Ko-r12jl.mjs → ContentInputField-BrtpTCDd.mjs} +11898 -903
- package/dist/admin/{ContentInputField-2hk9xG8p.js → ContentInputField-CQFQxxgm.js} +11934 -921
- package/dist/admin/{SurveyWidgetEditor-B3F4DE5r.js → SurveyWidgetEditor-C5Uvyf_h.js} +3992 -1086
- package/dist/admin/{SurveyWidgetEditor-B1S83aBE.mjs → SurveyWidgetEditor-DGSwgTzR.mjs} +4012 -1107
- package/dist/admin/{en-bneQpRJa.js → en-BZg845za.js} +2 -2
- package/dist/admin/{en-DnLdDKyq.mjs → en-C9LN2PJY.mjs} +2 -2
- package/dist/admin/{index-gn-4eO6g.mjs → index-Dc7AFLOj.mjs} +16 -6
- package/dist/admin/{index-B4FpXxnK.js → index-i0NfSYto.js} +16 -6
- package/dist/admin/index.js +1 -1
- package/dist/admin/index.mjs +1 -1
- package/dist/admin/src/components/color-codes/ColorCodesManager.d.ts +10 -0
- package/dist/admin/src/components/common/CIAspectRatioField.d.ts +35 -0
- package/dist/admin/src/components/common/CIColorField.d.ts +13 -0
- package/dist/admin/src/components/common/CIImageSettingsControl.d.ts +17 -0
- package/dist/admin/src/components/widgets/CustomCardWidgetEditor.d.ts +84 -0
- package/dist/admin/src/components/widgets/DataTableWidgetEditor.d.ts +65 -0
- package/dist/admin/src/components/widgets/EntityCardWidgetEditor.d.ts +10 -0
- package/dist/admin/src/components/widgets/HeroSliderStage.d.ts +156 -0
- package/dist/admin/src/components/widgets/HeroSliderWidgetEditor.d.ts +21 -0
- package/dist/admin/src/components/widgets/StrapiMediaPicker.d.ts +2 -0
- package/dist/admin/src/components/widgets/SurveyWidgetEditor.d.ts +1 -1
- package/dist/admin/src/core/canvasClasses.d.ts +1 -0
- package/dist/admin/src/core/colorUtils.d.ts +30 -0
- package/dist/admin/src/core/sampleData.d.ts +2 -1
- package/dist/admin/src/core/types.d.ts +12 -0
- package/dist/admin/src/core/useColorCodes.d.ts +43 -0
- package/dist/admin/{tr-00QqO0E7.mjs → tr-MtQFY92V.mjs} +2 -2
- package/dist/admin/{tr-O0nhB9er.js → tr-ZEmzAvKR.js} +2 -2
- package/dist/server/index.js +2162 -286
- package/dist/server/index.mjs +2162 -286
- package/dist/server/src/config/index.d.ts +4 -0
- package/dist/server/src/content-types/ci-color-palette/schema.json.d.ts +52 -0
- package/dist/server/src/content-types/index.d.ts +50 -0
- package/dist/server/src/controllers/ci-color.d.ts +14 -0
- package/dist/server/src/controllers/ci-image.d.ts +11 -2
- package/dist/server/src/controllers/index.d.ts +13 -0
- package/dist/server/src/index.d.ts +124 -0
- package/dist/server/src/services/ci-color.d.ts +127 -0
- package/dist/server/src/services/index.d.ts +57 -0
- package/dist/server/src/utils/image-variants.d.ts +74 -0
- package/dist/server/src/utils/mailer.d.ts +1 -0
- package/package.json +3 -2
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
declare const _default: {
|
|
2
|
+
"kind": "collectionType",
|
|
3
|
+
"collectionName": "ci_color_palettes",
|
|
4
|
+
"info": {
|
|
5
|
+
"singularName": "ci-color-palette",
|
|
6
|
+
"pluralName": "ci-color-palettes",
|
|
7
|
+
"displayName": "ContentInput Color Palette",
|
|
8
|
+
"description": "Theme color codes (HEX & RGB/RGBA semantic tokens + custom brand color tokens)"
|
|
9
|
+
},
|
|
10
|
+
"options": {
|
|
11
|
+
"draftAndPublish": false
|
|
12
|
+
},
|
|
13
|
+
"pluginOptions": {
|
|
14
|
+
"content-manager": {
|
|
15
|
+
"visible": false
|
|
16
|
+
},
|
|
17
|
+
"content-type-builder": {
|
|
18
|
+
"visible": false
|
|
19
|
+
}
|
|
20
|
+
},
|
|
21
|
+
"attributes": {
|
|
22
|
+
"name": {
|
|
23
|
+
"type": "string",
|
|
24
|
+
"required": true
|
|
25
|
+
},
|
|
26
|
+
"slug": {
|
|
27
|
+
"type": "string",
|
|
28
|
+
"required": true,
|
|
29
|
+
"unique": true
|
|
30
|
+
},
|
|
31
|
+
"description": {
|
|
32
|
+
"type": "string",
|
|
33
|
+
"default": ""
|
|
34
|
+
},
|
|
35
|
+
"isActive": {
|
|
36
|
+
"type": "boolean",
|
|
37
|
+
"default": false
|
|
38
|
+
},
|
|
39
|
+
"semanticTokens": {
|
|
40
|
+
"type": "json",
|
|
41
|
+
"required": true
|
|
42
|
+
},
|
|
43
|
+
"customTokens": {
|
|
44
|
+
"type": "json",
|
|
45
|
+
"default": []
|
|
46
|
+
}
|
|
47
|
+
}
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
;
|
|
51
|
+
|
|
52
|
+
export default _default;
|
|
@@ -399,5 +399,55 @@ declare const _default: {
|
|
|
399
399
|
};
|
|
400
400
|
};
|
|
401
401
|
};
|
|
402
|
+
'ci-color-palette': {
|
|
403
|
+
schema: {
|
|
404
|
+
kind: string;
|
|
405
|
+
collectionName: string;
|
|
406
|
+
info: {
|
|
407
|
+
singularName: string;
|
|
408
|
+
pluralName: string;
|
|
409
|
+
displayName: string;
|
|
410
|
+
description: string;
|
|
411
|
+
};
|
|
412
|
+
options: {
|
|
413
|
+
draftAndPublish: boolean;
|
|
414
|
+
};
|
|
415
|
+
pluginOptions: {
|
|
416
|
+
"content-manager": {
|
|
417
|
+
visible: boolean;
|
|
418
|
+
};
|
|
419
|
+
"content-type-builder": {
|
|
420
|
+
visible: boolean;
|
|
421
|
+
};
|
|
422
|
+
};
|
|
423
|
+
attributes: {
|
|
424
|
+
name: {
|
|
425
|
+
type: string;
|
|
426
|
+
required: boolean;
|
|
427
|
+
};
|
|
428
|
+
slug: {
|
|
429
|
+
type: string;
|
|
430
|
+
required: boolean;
|
|
431
|
+
unique: boolean;
|
|
432
|
+
};
|
|
433
|
+
description: {
|
|
434
|
+
type: string;
|
|
435
|
+
default: string;
|
|
436
|
+
};
|
|
437
|
+
isActive: {
|
|
438
|
+
type: string;
|
|
439
|
+
default: boolean;
|
|
440
|
+
};
|
|
441
|
+
semanticTokens: {
|
|
442
|
+
type: string;
|
|
443
|
+
required: boolean;
|
|
444
|
+
};
|
|
445
|
+
customTokens: {
|
|
446
|
+
type: string;
|
|
447
|
+
default: any[];
|
|
448
|
+
};
|
|
449
|
+
};
|
|
450
|
+
};
|
|
451
|
+
};
|
|
402
452
|
};
|
|
403
453
|
export default _default;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { Core } from '@strapi/strapi';
|
|
2
|
+
declare const ciColorController: ({ strapi }: {
|
|
3
|
+
strapi: Core.Strapi;
|
|
4
|
+
}) => {
|
|
5
|
+
indexAdmin(ctx: any): Promise<void>;
|
|
6
|
+
activePublic(ctx: any): Promise<void>;
|
|
7
|
+
save(ctx: any): Promise<void>;
|
|
8
|
+
activate(ctx: any): Promise<any>;
|
|
9
|
+
quickToken(ctx: any): Promise<any>;
|
|
10
|
+
delete(ctx: any): Promise<void>;
|
|
11
|
+
dataTableCollection(ctx: any): Promise<any>;
|
|
12
|
+
entityCardsBatch(ctx: any): Promise<any>;
|
|
13
|
+
};
|
|
14
|
+
export default ciColorController;
|
|
@@ -4,13 +4,22 @@ declare const ciImageController: ({ strapi }: {
|
|
|
4
4
|
}) => {
|
|
5
5
|
/**
|
|
6
6
|
* GET /api/content-input/image & GET /content-input/image
|
|
7
|
-
*
|
|
7
|
+
* Generates `ci-optimized` WebP variants via sharp, uploads to Strapi's Upload Provider (CDN),
|
|
8
|
+
* persists in `plugin::upload.file.formats`, and issues a 302 redirect when a remote CDN URL is available
|
|
9
|
+
* (with local byte-stream fallback in local-only environments).
|
|
8
10
|
*/
|
|
9
11
|
processImage(ctx: any): Promise<any>;
|
|
12
|
+
/**
|
|
13
|
+
* POST /content-input/media/optimize
|
|
14
|
+
* Eagerly optimizes one or multiple selected/uploaded Media Library assets into `ci-optimized/*.webp`
|
|
15
|
+
* on the configured Upload Provider (CDN) and returns enriched CIMediaAsset object(s) with `formats` & `optimized_url`.
|
|
16
|
+
*/
|
|
17
|
+
optimizeMedia(ctx: any): Promise<any>;
|
|
10
18
|
/**
|
|
11
19
|
* POST /content-input/media/crop
|
|
12
20
|
* Interactive crop & rotate using sharp on the backend (works seamlessly with local disk AND remote CDNs).
|
|
13
|
-
* Supports mode: 'replace' (crops original asset in Media Library
|
|
21
|
+
* Supports mode: 'replace' (crops original asset in Media Library & refreshes ci-optimized variants)
|
|
22
|
+
* or 'duplicate' (saves as new asset).
|
|
14
23
|
*/
|
|
15
24
|
cropMedia(ctx: any): Promise<any>;
|
|
16
25
|
/**
|
|
@@ -20,6 +20,7 @@ declare const _default: {
|
|
|
20
20
|
strapi: import('@strapi/types/dist/core/strapi.js').Strapi;
|
|
21
21
|
}) => {
|
|
22
22
|
processImage(ctx: any): Promise<any>;
|
|
23
|
+
optimizeMedia(ctx: any): Promise<any>;
|
|
23
24
|
cropMedia(ctx: any): Promise<any>;
|
|
24
25
|
updateMediaInfo(ctx: any): Promise<any>;
|
|
25
26
|
deleteMedia(ctx: any): Promise<any>;
|
|
@@ -56,5 +57,17 @@ declare const _default: {
|
|
|
56
57
|
exportResponses(ctx: any): Promise<any>;
|
|
57
58
|
reseedDemo(ctx: any): Promise<void>;
|
|
58
59
|
};
|
|
60
|
+
'ci-color': ({ strapi }: {
|
|
61
|
+
strapi: import('@strapi/types/dist/core/strapi.js').Strapi;
|
|
62
|
+
}) => {
|
|
63
|
+
indexAdmin(ctx: any): Promise<void>;
|
|
64
|
+
activePublic(ctx: any): Promise<void>;
|
|
65
|
+
save(ctx: any): Promise<void>;
|
|
66
|
+
activate(ctx: any): Promise<any>;
|
|
67
|
+
quickToken(ctx: any): Promise<any>;
|
|
68
|
+
delete(ctx: any): Promise<void>;
|
|
69
|
+
dataTableCollection(ctx: any): Promise<any>;
|
|
70
|
+
entityCardsBatch(ctx: any): Promise<any>;
|
|
71
|
+
};
|
|
59
72
|
};
|
|
60
73
|
export default _default;
|
|
@@ -11,6 +11,10 @@ declare const _default: {
|
|
|
11
11
|
config: {
|
|
12
12
|
default: {
|
|
13
13
|
previewUrl: string;
|
|
14
|
+
imageVariantFolder: string;
|
|
15
|
+
imageVariantFormat: string;
|
|
16
|
+
imageVariantQuality: number;
|
|
17
|
+
redirectProxyToCdn: boolean;
|
|
14
18
|
};
|
|
15
19
|
validator(): void;
|
|
16
20
|
};
|
|
@@ -36,6 +40,7 @@ declare const _default: {
|
|
|
36
40
|
strapi: import('@strapi/types/dist/core/strapi.js').Strapi;
|
|
37
41
|
}) => {
|
|
38
42
|
processImage(ctx: any): Promise<any>;
|
|
43
|
+
optimizeMedia(ctx: any): Promise<any>;
|
|
39
44
|
cropMedia(ctx: any): Promise<any>;
|
|
40
45
|
updateMediaInfo(ctx: any): Promise<any>;
|
|
41
46
|
deleteMedia(ctx: any): Promise<any>;
|
|
@@ -72,6 +77,18 @@ declare const _default: {
|
|
|
72
77
|
exportResponses(ctx: any): Promise<any>;
|
|
73
78
|
reseedDemo(ctx: any): Promise<void>;
|
|
74
79
|
};
|
|
80
|
+
'ci-color': ({ strapi }: {
|
|
81
|
+
strapi: import('@strapi/types/dist/core/strapi.js').Strapi;
|
|
82
|
+
}) => {
|
|
83
|
+
indexAdmin(ctx: any): Promise<void>;
|
|
84
|
+
activePublic(ctx: any): Promise<void>;
|
|
85
|
+
save(ctx: any): Promise<void>;
|
|
86
|
+
activate(ctx: any): Promise<any>;
|
|
87
|
+
quickToken(ctx: any): Promise<any>;
|
|
88
|
+
delete(ctx: any): Promise<void>;
|
|
89
|
+
dataTableCollection(ctx: any): Promise<any>;
|
|
90
|
+
entityCardsBatch(ctx: any): Promise<any>;
|
|
91
|
+
};
|
|
75
92
|
};
|
|
76
93
|
routes: {
|
|
77
94
|
admin: {
|
|
@@ -540,6 +557,63 @@ declare const _default: {
|
|
|
540
557
|
body: string;
|
|
541
558
|
}>;
|
|
542
559
|
};
|
|
560
|
+
'ci-color': ({ strapi }: {
|
|
561
|
+
strapi: import('@strapi/types/dist/core/strapi.js').Strapi;
|
|
562
|
+
}) => {
|
|
563
|
+
ensureSeeded(): Promise<void>;
|
|
564
|
+
findAll(): Promise<{
|
|
565
|
+
data: any[];
|
|
566
|
+
active: any;
|
|
567
|
+
cssVariables: Record<string, string>;
|
|
568
|
+
}>;
|
|
569
|
+
findActivePublic(slugOverride?: string): Promise<{
|
|
570
|
+
data: any;
|
|
571
|
+
palette: any;
|
|
572
|
+
palettes: {
|
|
573
|
+
name: any;
|
|
574
|
+
slug: any;
|
|
575
|
+
isActive: boolean;
|
|
576
|
+
primary: any;
|
|
577
|
+
secondary: any;
|
|
578
|
+
accent: any;
|
|
579
|
+
}[];
|
|
580
|
+
cssVariables: Record<string, string>;
|
|
581
|
+
}>;
|
|
582
|
+
save(payload: any): Promise<any>;
|
|
583
|
+
activate(idOrSlug: string | number): Promise<any>;
|
|
584
|
+
upsertQuickCustomToken(input: {
|
|
585
|
+
key: string;
|
|
586
|
+
label?: string;
|
|
587
|
+
labels?: Record<string, string>;
|
|
588
|
+
value: string;
|
|
589
|
+
}): Promise<any>;
|
|
590
|
+
remove(idOrSlug: string | number): Promise<any>;
|
|
591
|
+
queryCollectionForDataTable(params: {
|
|
592
|
+
uid: string;
|
|
593
|
+
limit?: number;
|
|
594
|
+
sort?: string;
|
|
595
|
+
}): Promise<{
|
|
596
|
+
columns: any[];
|
|
597
|
+
rows: any[];
|
|
598
|
+
uid?: undefined;
|
|
599
|
+
displayName?: undefined;
|
|
600
|
+
availableFields?: undefined;
|
|
601
|
+
} | {
|
|
602
|
+
uid: string;
|
|
603
|
+
displayName: any;
|
|
604
|
+
availableFields: {
|
|
605
|
+
key: string;
|
|
606
|
+
type: string;
|
|
607
|
+
}[];
|
|
608
|
+
rows: Record<string, any>[];
|
|
609
|
+
columns?: undefined;
|
|
610
|
+
}>;
|
|
611
|
+
resolveEntityCardsBatch(params: {
|
|
612
|
+
uid: string;
|
|
613
|
+
documentIds?: string[];
|
|
614
|
+
limit?: number;
|
|
615
|
+
}): Promise<any[]>;
|
|
616
|
+
};
|
|
543
617
|
};
|
|
544
618
|
contentTypes: {
|
|
545
619
|
'ci-template': {
|
|
@@ -942,6 +1016,56 @@ declare const _default: {
|
|
|
942
1016
|
};
|
|
943
1017
|
};
|
|
944
1018
|
};
|
|
1019
|
+
'ci-color-palette': {
|
|
1020
|
+
schema: {
|
|
1021
|
+
kind: string;
|
|
1022
|
+
collectionName: string;
|
|
1023
|
+
info: {
|
|
1024
|
+
singularName: string;
|
|
1025
|
+
pluralName: string;
|
|
1026
|
+
displayName: string;
|
|
1027
|
+
description: string;
|
|
1028
|
+
};
|
|
1029
|
+
options: {
|
|
1030
|
+
draftAndPublish: boolean;
|
|
1031
|
+
};
|
|
1032
|
+
pluginOptions: {
|
|
1033
|
+
"content-manager": {
|
|
1034
|
+
visible: boolean;
|
|
1035
|
+
};
|
|
1036
|
+
"content-type-builder": {
|
|
1037
|
+
visible: boolean;
|
|
1038
|
+
};
|
|
1039
|
+
};
|
|
1040
|
+
attributes: {
|
|
1041
|
+
name: {
|
|
1042
|
+
type: string;
|
|
1043
|
+
required: boolean;
|
|
1044
|
+
};
|
|
1045
|
+
slug: {
|
|
1046
|
+
type: string;
|
|
1047
|
+
required: boolean;
|
|
1048
|
+
unique: boolean;
|
|
1049
|
+
};
|
|
1050
|
+
description: {
|
|
1051
|
+
type: string;
|
|
1052
|
+
default: string;
|
|
1053
|
+
};
|
|
1054
|
+
isActive: {
|
|
1055
|
+
type: string;
|
|
1056
|
+
default: boolean;
|
|
1057
|
+
};
|
|
1058
|
+
semanticTokens: {
|
|
1059
|
+
type: string;
|
|
1060
|
+
required: boolean;
|
|
1061
|
+
};
|
|
1062
|
+
customTokens: {
|
|
1063
|
+
type: string;
|
|
1064
|
+
default: any[];
|
|
1065
|
+
};
|
|
1066
|
+
};
|
|
1067
|
+
};
|
|
1068
|
+
};
|
|
945
1069
|
};
|
|
946
1070
|
};
|
|
947
1071
|
export default _default;
|
|
@@ -0,0 +1,127 @@
|
|
|
1
|
+
import { Core } from '@strapi/strapi';
|
|
2
|
+
export interface ParsedRgba {
|
|
3
|
+
r: number;
|
|
4
|
+
g: number;
|
|
5
|
+
b: number;
|
|
6
|
+
a: number;
|
|
7
|
+
}
|
|
8
|
+
export interface SemanticTokenEntry {
|
|
9
|
+
value: string;
|
|
10
|
+
hex: string;
|
|
11
|
+
rgb: string;
|
|
12
|
+
soft: string;
|
|
13
|
+
contrast: string;
|
|
14
|
+
labels?: Record<string, string>;
|
|
15
|
+
}
|
|
16
|
+
export interface CustomTokenEntry {
|
|
17
|
+
key: string;
|
|
18
|
+
value: string;
|
|
19
|
+
hex: string;
|
|
20
|
+
rgb: string;
|
|
21
|
+
soft: string;
|
|
22
|
+
contrast: string;
|
|
23
|
+
labels: Record<string, string>;
|
|
24
|
+
}
|
|
25
|
+
export declare function parseColorToRgba(rawInput: string, fallback?: ParsedRgba): ParsedRgba;
|
|
26
|
+
export declare function rgbaToHex({ r, g, b, a }: ParsedRgba): string;
|
|
27
|
+
export declare function rgbaToCssString({ r, g, b, a }: ParsedRgba): string;
|
|
28
|
+
export declare function buildTokenEntry(rawVal: string, labels?: Record<string, string>, overrides?: Partial<SemanticTokenEntry>): SemanticTokenEntry;
|
|
29
|
+
export declare const SEMANTIC_TOKEN_META: Array<{
|
|
30
|
+
key: string;
|
|
31
|
+
tr: string;
|
|
32
|
+
en: string;
|
|
33
|
+
}>;
|
|
34
|
+
export declare const DEFAULT_PALETTE_SEEDS: {
|
|
35
|
+
name: string;
|
|
36
|
+
slug: string;
|
|
37
|
+
description: string;
|
|
38
|
+
isActive: boolean;
|
|
39
|
+
rawSemantic: {
|
|
40
|
+
primary: string;
|
|
41
|
+
secondary: string;
|
|
42
|
+
accent: string;
|
|
43
|
+
success: string;
|
|
44
|
+
warning: string;
|
|
45
|
+
error: string;
|
|
46
|
+
info: string;
|
|
47
|
+
surface: string;
|
|
48
|
+
surfaceAlt: string;
|
|
49
|
+
background: string;
|
|
50
|
+
textPrimary: string;
|
|
51
|
+
textSecondary: string;
|
|
52
|
+
border: string;
|
|
53
|
+
};
|
|
54
|
+
rawCustom: {
|
|
55
|
+
key: string;
|
|
56
|
+
value: string;
|
|
57
|
+
labels: {
|
|
58
|
+
tr: string;
|
|
59
|
+
en: string;
|
|
60
|
+
};
|
|
61
|
+
}[];
|
|
62
|
+
}[];
|
|
63
|
+
export declare function buildCssVariablesMap(palette: any): Record<string, string>;
|
|
64
|
+
declare const ciColorService: ({ strapi }: {
|
|
65
|
+
strapi: Core.Strapi;
|
|
66
|
+
}) => {
|
|
67
|
+
ensureSeeded(): Promise<void>;
|
|
68
|
+
findAll(): Promise<{
|
|
69
|
+
data: any[];
|
|
70
|
+
active: any;
|
|
71
|
+
cssVariables: Record<string, string>;
|
|
72
|
+
}>;
|
|
73
|
+
findActivePublic(slugOverride?: string): Promise<{
|
|
74
|
+
data: any;
|
|
75
|
+
palette: any;
|
|
76
|
+
palettes: {
|
|
77
|
+
name: any;
|
|
78
|
+
slug: any;
|
|
79
|
+
isActive: boolean;
|
|
80
|
+
primary: any;
|
|
81
|
+
secondary: any;
|
|
82
|
+
accent: any;
|
|
83
|
+
}[];
|
|
84
|
+
cssVariables: Record<string, string>;
|
|
85
|
+
}>;
|
|
86
|
+
save(payload: any): Promise<any>;
|
|
87
|
+
activate(idOrSlug: string | number): Promise<any>;
|
|
88
|
+
upsertQuickCustomToken(input: {
|
|
89
|
+
key: string;
|
|
90
|
+
label?: string;
|
|
91
|
+
labels?: Record<string, string>;
|
|
92
|
+
value: string;
|
|
93
|
+
}): Promise<any>;
|
|
94
|
+
remove(idOrSlug: string | number): Promise<any>;
|
|
95
|
+
/**
|
|
96
|
+
* Safe public collection query for Data Table (`sourceMode: 'strapi_collection'`)
|
|
97
|
+
*/
|
|
98
|
+
queryCollectionForDataTable(params: {
|
|
99
|
+
uid: string;
|
|
100
|
+
limit?: number;
|
|
101
|
+
sort?: string;
|
|
102
|
+
}): Promise<{
|
|
103
|
+
columns: any[];
|
|
104
|
+
rows: any[];
|
|
105
|
+
uid?: undefined;
|
|
106
|
+
displayName?: undefined;
|
|
107
|
+
availableFields?: undefined;
|
|
108
|
+
} | {
|
|
109
|
+
uid: string;
|
|
110
|
+
displayName: any;
|
|
111
|
+
availableFields: {
|
|
112
|
+
key: string;
|
|
113
|
+
type: string;
|
|
114
|
+
}[];
|
|
115
|
+
rows: Record<string, any>[];
|
|
116
|
+
columns?: undefined;
|
|
117
|
+
}>;
|
|
118
|
+
/**
|
|
119
|
+
* Batch Entity Cards resolver for `entityCard` Swiper Carousel & Grid modes
|
|
120
|
+
*/
|
|
121
|
+
resolveEntityCardsBatch(params: {
|
|
122
|
+
uid: string;
|
|
123
|
+
documentIds?: string[];
|
|
124
|
+
limit?: number;
|
|
125
|
+
}): Promise<any[]>;
|
|
126
|
+
};
|
|
127
|
+
export default ciColorService;
|
|
@@ -431,5 +431,62 @@ declare const _default: {
|
|
|
431
431
|
body: string;
|
|
432
432
|
}>;
|
|
433
433
|
};
|
|
434
|
+
'ci-color': ({ strapi }: {
|
|
435
|
+
strapi: import('@strapi/types/dist/core/strapi.js').Strapi;
|
|
436
|
+
}) => {
|
|
437
|
+
ensureSeeded(): Promise<void>;
|
|
438
|
+
findAll(): Promise<{
|
|
439
|
+
data: any[];
|
|
440
|
+
active: any;
|
|
441
|
+
cssVariables: Record<string, string>;
|
|
442
|
+
}>;
|
|
443
|
+
findActivePublic(slugOverride?: string): Promise<{
|
|
444
|
+
data: any;
|
|
445
|
+
palette: any;
|
|
446
|
+
palettes: {
|
|
447
|
+
name: any;
|
|
448
|
+
slug: any;
|
|
449
|
+
isActive: boolean;
|
|
450
|
+
primary: any;
|
|
451
|
+
secondary: any;
|
|
452
|
+
accent: any;
|
|
453
|
+
}[];
|
|
454
|
+
cssVariables: Record<string, string>;
|
|
455
|
+
}>;
|
|
456
|
+
save(payload: any): Promise<any>;
|
|
457
|
+
activate(idOrSlug: string | number): Promise<any>;
|
|
458
|
+
upsertQuickCustomToken(input: {
|
|
459
|
+
key: string;
|
|
460
|
+
label?: string;
|
|
461
|
+
labels?: Record<string, string>;
|
|
462
|
+
value: string;
|
|
463
|
+
}): Promise<any>;
|
|
464
|
+
remove(idOrSlug: string | number): Promise<any>;
|
|
465
|
+
queryCollectionForDataTable(params: {
|
|
466
|
+
uid: string;
|
|
467
|
+
limit?: number;
|
|
468
|
+
sort?: string;
|
|
469
|
+
}): Promise<{
|
|
470
|
+
columns: any[];
|
|
471
|
+
rows: any[];
|
|
472
|
+
uid?: undefined;
|
|
473
|
+
displayName?: undefined;
|
|
474
|
+
availableFields?: undefined;
|
|
475
|
+
} | {
|
|
476
|
+
uid: string;
|
|
477
|
+
displayName: any;
|
|
478
|
+
availableFields: {
|
|
479
|
+
key: string;
|
|
480
|
+
type: string;
|
|
481
|
+
}[];
|
|
482
|
+
rows: Record<string, any>[];
|
|
483
|
+
columns?: undefined;
|
|
484
|
+
}>;
|
|
485
|
+
resolveEntityCardsBatch(params: {
|
|
486
|
+
uid: string;
|
|
487
|
+
documentIds?: string[];
|
|
488
|
+
limit?: number;
|
|
489
|
+
}): Promise<any[]>;
|
|
490
|
+
};
|
|
434
491
|
};
|
|
435
492
|
export default _default;
|
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
import { Core } from '@strapi/strapi';
|
|
2
|
+
export interface VariantRuntimeConfig {
|
|
3
|
+
folder: string | null;
|
|
4
|
+
defaultFormat: 'webp' | 'auto';
|
|
5
|
+
redirectProxyToCdn: boolean;
|
|
6
|
+
defaultQuality: number;
|
|
7
|
+
}
|
|
8
|
+
export interface ImageProcessSpec {
|
|
9
|
+
processMode: 'fit' | 'widen' | 'auto' | 'none';
|
|
10
|
+
w: number;
|
|
11
|
+
h: number;
|
|
12
|
+
maxW: number;
|
|
13
|
+
q: number;
|
|
14
|
+
rotate: number;
|
|
15
|
+
requestedFormat?: string;
|
|
16
|
+
}
|
|
17
|
+
export declare function getSharp(): any;
|
|
18
|
+
export declare function getVariantConfig(strapi: Core.Strapi): VariantRuntimeConfig;
|
|
19
|
+
export declare function isAbsoluteHttpUrl(url?: string | null): boolean;
|
|
20
|
+
export declare function isOptimizableRasterImage(mime?: string | null, urlOrName?: string | null): boolean;
|
|
21
|
+
export declare function loadSourceBuffer(strapi: Core.Strapi, src: string): Promise<{
|
|
22
|
+
buffer: Buffer;
|
|
23
|
+
mime: string;
|
|
24
|
+
}>;
|
|
25
|
+
export declare function normalizeImageProcessSpec(imageSettings?: Record<string, any> | null, defaultAutoMaxW?: number): ImageProcessSpec;
|
|
26
|
+
export declare function computeCiFormatKey(processMode: 'fit' | 'widen' | 'auto', w: number, h: number, rotate?: number): string;
|
|
27
|
+
export declare function compactAssetFormats(formats?: Record<string, any> | null): Record<string, {
|
|
28
|
+
url: string;
|
|
29
|
+
width?: number;
|
|
30
|
+
height?: number;
|
|
31
|
+
mime?: string;
|
|
32
|
+
size?: number;
|
|
33
|
+
}> | undefined;
|
|
34
|
+
export declare function findUploadFileForAsset(strapi: Core.Strapi, assetOrUrl: any, cache?: Map<string, any>): Promise<any | null>;
|
|
35
|
+
export declare function renderSharpVariantBuffer(sourceBuffer: Buffer, sourceMime: string, opts: {
|
|
36
|
+
processMode: 'fit' | 'widen' | 'auto';
|
|
37
|
+
w: number;
|
|
38
|
+
h: number;
|
|
39
|
+
q: number;
|
|
40
|
+
rotate?: number;
|
|
41
|
+
cx?: number;
|
|
42
|
+
cy?: number;
|
|
43
|
+
cw?: number;
|
|
44
|
+
ch?: number;
|
|
45
|
+
requestedFormat?: string;
|
|
46
|
+
defaultFormat?: 'webp' | 'auto';
|
|
47
|
+
}): Promise<{
|
|
48
|
+
buffer: Buffer;
|
|
49
|
+
contentType: string;
|
|
50
|
+
ext: string;
|
|
51
|
+
width?: number;
|
|
52
|
+
height?: number;
|
|
53
|
+
}>;
|
|
54
|
+
export declare function ensureMediaVariant(strapi: Core.Strapi, existingFile: any, spec: {
|
|
55
|
+
processMode: 'fit' | 'widen' | 'auto';
|
|
56
|
+
w: number;
|
|
57
|
+
h: number;
|
|
58
|
+
q?: number;
|
|
59
|
+
rotate?: number;
|
|
60
|
+
requestedFormat?: string;
|
|
61
|
+
}): Promise<{
|
|
62
|
+
formatKey: string;
|
|
63
|
+
formatEntry: any | null;
|
|
64
|
+
updatedFile: any;
|
|
65
|
+
}>;
|
|
66
|
+
export declare function clearGeneratedCiVariantsForFile(strapi: Core.Strapi, fileRecord: any): Promise<void>;
|
|
67
|
+
export declare function enrichMediaAssetNode(strapi: Core.Strapi, asset: any, opts?: {
|
|
68
|
+
imageSettings?: Record<string, any> | null;
|
|
69
|
+
defaultAutoMaxW?: number;
|
|
70
|
+
alsoEnsureAutoMaxW?: number;
|
|
71
|
+
fileCache?: Map<string, any>;
|
|
72
|
+
}): Promise<any>;
|
|
73
|
+
export declare function syncContentInputTreeMedia(strapi: Core.Strapi, rawValue: any): Promise<any>;
|
|
74
|
+
export declare function syncSurveyQuestionsMedia(strapi: Core.Strapi, questions: any[]): Promise<any[]>;
|
|
@@ -33,6 +33,7 @@ export declare function renderContentFormMailHtml(params: SendFormMailParams): {
|
|
|
33
33
|
html: string;
|
|
34
34
|
text: string;
|
|
35
35
|
};
|
|
36
|
+
export declare function discoverMailtrapSandboxInbox(rawToken?: string): Promise<string>;
|
|
36
37
|
export declare function sendDynamicFormMail(params: SendFormMailParams): Promise<{
|
|
37
38
|
sent: boolean;
|
|
38
39
|
driver: string;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ozguraltan/strapi-content-input",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.22",
|
|
4
4
|
"description": "Locomotive CMS ContentInput visual page/content builder ported to Strapi v5 as a native JSONB Custom Field plugin.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"author": "Ozgur Altan <ozguraltan05@gmail.com>",
|
|
@@ -70,7 +70,8 @@
|
|
|
70
70
|
"@strapi/icons": "^2.0.0",
|
|
71
71
|
"lodash": "^4.17.21",
|
|
72
72
|
"react-intl": "^6.6.2",
|
|
73
|
-
"swiper": "^14.4.0"
|
|
73
|
+
"swiper": "^14.4.0",
|
|
74
|
+
"xlsx": "^0.18.5"
|
|
74
75
|
},
|
|
75
76
|
"devDependencies": {
|
|
76
77
|
"@strapi/sdk-plugin": "^6.1.1",
|