@cooperco/cooper-component-library 0.1.73 → 0.1.74
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/cms/0064-create-placeholder-module.cjs +37 -0
- package/dist/cms/contentModule.query.ts +1 -0
- package/dist/cms/contentful/migrations/scripts/0064-create-placeholder-module.cjs +37 -0
- package/dist/cms/contentful/queries/contentModule.query.js +1 -0
- package/dist/cms/contentful/queries/contentModule.query.ts +1 -0
- package/dist/cms/migrations/scripts/0064-create-placeholder-module.cjs +37 -0
- package/dist/cms/queries/contentModule.query.ts +1 -0
- package/dist/cms/scripts/0064-create-placeholder-module.cjs +37 -0
- package/package.json +113 -112
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
module.exports = {
|
|
2
|
+
// @ts-check
|
|
3
|
+
/** @type { import('contentful-migration').MigrationFunction } */
|
|
4
|
+
up: function (migration) {
|
|
5
|
+
const contentModule = migration.editContentType('contentModule')
|
|
6
|
+
|
|
7
|
+
contentModule
|
|
8
|
+
.createField('placeholderModule')
|
|
9
|
+
.name('Placeholder Module')
|
|
10
|
+
.type('Symbol')
|
|
11
|
+
.required(false)
|
|
12
|
+
.validations([
|
|
13
|
+
{
|
|
14
|
+
in: ['Contact Us'],
|
|
15
|
+
},
|
|
16
|
+
])
|
|
17
|
+
|
|
18
|
+
contentModule.changeFieldControl(
|
|
19
|
+
'placeholderModule',
|
|
20
|
+
'builtin',
|
|
21
|
+
'dropdown',
|
|
22
|
+
{
|
|
23
|
+
"helpText": "If a placeholder is selected, the fields below will be ignored.",
|
|
24
|
+
}
|
|
25
|
+
)
|
|
26
|
+
|
|
27
|
+
contentModule.moveField('placeholderModule').beforeField('logo')
|
|
28
|
+
},
|
|
29
|
+
|
|
30
|
+
// @ts-check
|
|
31
|
+
/** @type { import('contentful-migration').MigrationFunction } */
|
|
32
|
+
down: async function (migration) {
|
|
33
|
+
const contentModule = migration.editContentType('contentModule')
|
|
34
|
+
contentModule.deleteField('placeholderModule')
|
|
35
|
+
},
|
|
36
|
+
}
|
|
37
|
+
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
module.exports = {
|
|
2
|
+
// @ts-check
|
|
3
|
+
/** @type { import('contentful-migration').MigrationFunction } */
|
|
4
|
+
up: function (migration) {
|
|
5
|
+
const contentModule = migration.editContentType('contentModule')
|
|
6
|
+
|
|
7
|
+
contentModule
|
|
8
|
+
.createField('placeholderModule')
|
|
9
|
+
.name('Placeholder Module')
|
|
10
|
+
.type('Symbol')
|
|
11
|
+
.required(false)
|
|
12
|
+
.validations([
|
|
13
|
+
{
|
|
14
|
+
in: ['Contact Us'],
|
|
15
|
+
},
|
|
16
|
+
])
|
|
17
|
+
|
|
18
|
+
contentModule.changeFieldControl(
|
|
19
|
+
'placeholderModule',
|
|
20
|
+
'builtin',
|
|
21
|
+
'dropdown',
|
|
22
|
+
{
|
|
23
|
+
"helpText": "If a placeholder is selected, the fields below will be ignored.",
|
|
24
|
+
}
|
|
25
|
+
)
|
|
26
|
+
|
|
27
|
+
contentModule.moveField('placeholderModule').beforeField('logo')
|
|
28
|
+
},
|
|
29
|
+
|
|
30
|
+
// @ts-check
|
|
31
|
+
/** @type { import('contentful-migration').MigrationFunction } */
|
|
32
|
+
down: async function (migration) {
|
|
33
|
+
const contentModule = migration.editContentType('contentModule')
|
|
34
|
+
contentModule.deleteField('placeholderModule')
|
|
35
|
+
},
|
|
36
|
+
}
|
|
37
|
+
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
module.exports = {
|
|
2
|
+
// @ts-check
|
|
3
|
+
/** @type { import('contentful-migration').MigrationFunction } */
|
|
4
|
+
up: function (migration) {
|
|
5
|
+
const contentModule = migration.editContentType('contentModule')
|
|
6
|
+
|
|
7
|
+
contentModule
|
|
8
|
+
.createField('placeholderModule')
|
|
9
|
+
.name('Placeholder Module')
|
|
10
|
+
.type('Symbol')
|
|
11
|
+
.required(false)
|
|
12
|
+
.validations([
|
|
13
|
+
{
|
|
14
|
+
in: ['Contact Us'],
|
|
15
|
+
},
|
|
16
|
+
])
|
|
17
|
+
|
|
18
|
+
contentModule.changeFieldControl(
|
|
19
|
+
'placeholderModule',
|
|
20
|
+
'builtin',
|
|
21
|
+
'dropdown',
|
|
22
|
+
{
|
|
23
|
+
"helpText": "If a placeholder is selected, the fields below will be ignored.",
|
|
24
|
+
}
|
|
25
|
+
)
|
|
26
|
+
|
|
27
|
+
contentModule.moveField('placeholderModule').beforeField('logo')
|
|
28
|
+
},
|
|
29
|
+
|
|
30
|
+
// @ts-check
|
|
31
|
+
/** @type { import('contentful-migration').MigrationFunction } */
|
|
32
|
+
down: async function (migration) {
|
|
33
|
+
const contentModule = migration.editContentType('contentModule')
|
|
34
|
+
contentModule.deleteField('placeholderModule')
|
|
35
|
+
},
|
|
36
|
+
}
|
|
37
|
+
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
module.exports = {
|
|
2
|
+
// @ts-check
|
|
3
|
+
/** @type { import('contentful-migration').MigrationFunction } */
|
|
4
|
+
up: function (migration) {
|
|
5
|
+
const contentModule = migration.editContentType('contentModule')
|
|
6
|
+
|
|
7
|
+
contentModule
|
|
8
|
+
.createField('placeholderModule')
|
|
9
|
+
.name('Placeholder Module')
|
|
10
|
+
.type('Symbol')
|
|
11
|
+
.required(false)
|
|
12
|
+
.validations([
|
|
13
|
+
{
|
|
14
|
+
in: ['Contact Us'],
|
|
15
|
+
},
|
|
16
|
+
])
|
|
17
|
+
|
|
18
|
+
contentModule.changeFieldControl(
|
|
19
|
+
'placeholderModule',
|
|
20
|
+
'builtin',
|
|
21
|
+
'dropdown',
|
|
22
|
+
{
|
|
23
|
+
"helpText": "If a placeholder is selected, the fields below will be ignored.",
|
|
24
|
+
}
|
|
25
|
+
)
|
|
26
|
+
|
|
27
|
+
contentModule.moveField('placeholderModule').beforeField('logo')
|
|
28
|
+
},
|
|
29
|
+
|
|
30
|
+
// @ts-check
|
|
31
|
+
/** @type { import('contentful-migration').MigrationFunction } */
|
|
32
|
+
down: async function (migration) {
|
|
33
|
+
const contentModule = migration.editContentType('contentModule')
|
|
34
|
+
contentModule.deleteField('placeholderModule')
|
|
35
|
+
},
|
|
36
|
+
}
|
|
37
|
+
|
package/package.json
CHANGED
|
@@ -1,113 +1,114 @@
|
|
|
1
1
|
{
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
}
|
|
2
|
+
"name": "@cooperco/cooper-component-library",
|
|
3
|
+
"private": false,
|
|
4
|
+
"version": "0.1.74",
|
|
5
|
+
"type": "module",
|
|
6
|
+
"files": [
|
|
7
|
+
"dist"
|
|
8
|
+
],
|
|
9
|
+
"main": "./dist/lib/component-lib.umd.cjs",
|
|
10
|
+
"module": "./dist/lib/component-lib.js",
|
|
11
|
+
"types": "./dist/types/src/index.d.ts",
|
|
12
|
+
"exports": {
|
|
13
|
+
".": {
|
|
14
|
+
"import": "./dist/lib/component-lib.js",
|
|
15
|
+
"require": "./dist/lib/component-lib.umd.cjs",
|
|
16
|
+
"types": "./dist/types/src/index.d.ts"
|
|
17
|
+
},
|
|
18
|
+
"./css/main.css": {
|
|
19
|
+
"import": "./dist/lib/css/main.css",
|
|
20
|
+
"require": "./dist/lib/css/main.css"
|
|
21
|
+
},
|
|
22
|
+
"./css/theme.css": {
|
|
23
|
+
"import": "./dist/lib/css/theme.css",
|
|
24
|
+
"require": "./dist/lib/css/theme.css"
|
|
25
|
+
},
|
|
26
|
+
"./cms/contentful/graphql": {
|
|
27
|
+
"import": "./dist/cms/contentful/queries/index.js",
|
|
28
|
+
"types": "./dist/cms/contentful/queries/index.d.ts"
|
|
29
|
+
}
|
|
30
|
+
},
|
|
31
|
+
"scripts": {
|
|
32
|
+
"dev": "vite",
|
|
33
|
+
"check-types": "vue-tsc",
|
|
34
|
+
"build:types": "vue-tsc --emitDeclarationOnly --outDir dist/types",
|
|
35
|
+
"build:cms": "tsc -p tsconfig.cms.json",
|
|
36
|
+
"build": "pnpm run build:types && pnpm run build:cms && vite build",
|
|
37
|
+
"preview": "vite preview",
|
|
38
|
+
"tail": "tailwind-config-viewer -o",
|
|
39
|
+
"storybook": "storybook dev -p 6006",
|
|
40
|
+
"build-storybook": "storybook build",
|
|
41
|
+
"chromatic": "chromatic --exit-zero-on-changes",
|
|
42
|
+
"prepare": "husky",
|
|
43
|
+
"lint": "eslint . --no-fix",
|
|
44
|
+
"lint:fix": "eslint . --fix --quiet",
|
|
45
|
+
"local-test": "pnpm run build && pnpm pack"
|
|
46
|
+
},
|
|
47
|
+
"dependencies": {
|
|
48
|
+
"@primevue/themes": "^4.0.0",
|
|
49
|
+
"@vueuse/components": "^11.1.0",
|
|
50
|
+
"@vueuse/core": "^11.1.0",
|
|
51
|
+
"contentful-management": "^11.68.0",
|
|
52
|
+
"contentful-migration": "^4.23.2",
|
|
53
|
+
"dotenv": "^17.2.3",
|
|
54
|
+
"graphql": "^16.9.0",
|
|
55
|
+
"graphql-tag": "^2.12.6",
|
|
56
|
+
"primeicons": "^7.0.0",
|
|
57
|
+
"primevue": "^3.0.0",
|
|
58
|
+
"tailwind-merge": "^2.4.0",
|
|
59
|
+
"vite-plugin-turbosnap": "^1.0.3",
|
|
60
|
+
"vue": "^3.5.6"
|
|
61
|
+
},
|
|
62
|
+
"devDependencies": {
|
|
63
|
+
"@chromatic-com/storybook": "^3.2.6",
|
|
64
|
+
"@cooperco/contentful-cli-migrations": "^0.5.2",
|
|
65
|
+
"@eslint/js": "^9.4.0",
|
|
66
|
+
"@storybook/addon-essentials": "^8.6.15",
|
|
67
|
+
"@storybook/addon-interactions": "^8.6.15",
|
|
68
|
+
"@storybook/addon-links": "^8.6.15",
|
|
69
|
+
"@storybook/blocks": "^8.6.15",
|
|
70
|
+
"@storybook/builder-vite": "^8.6.15",
|
|
71
|
+
"@storybook/test": "^8.6.15",
|
|
72
|
+
"@storybook/vue3": "^8.6.15",
|
|
73
|
+
"@storybook/vue3-vite": "^8.6.15",
|
|
74
|
+
"@tsconfig/node18": "^18.2.4",
|
|
75
|
+
"@typescript-eslint/eslint-plugin": "^8.24.1",
|
|
76
|
+
"@typescript-eslint/parser": "^8.24.1",
|
|
77
|
+
"@vitejs/plugin-vue": "^5.0.4",
|
|
78
|
+
"@vue/tsconfig": "^0.5.1",
|
|
79
|
+
"autoprefixer": "^10.4.19",
|
|
80
|
+
"chromatic": "^15.1.0",
|
|
81
|
+
"eslint": "^8.57.0",
|
|
82
|
+
"eslint-config-prettier": "^9.1.0",
|
|
83
|
+
"eslint-plugin-vue": "^9.26.0",
|
|
84
|
+
"globals": "^15.3.0",
|
|
85
|
+
"husky": "^9.1.4",
|
|
86
|
+
"jsdom": "^24.1.0",
|
|
87
|
+
"lint-staged": "^15.2.8",
|
|
88
|
+
"patch-package": "^8.0.0",
|
|
89
|
+
"postcss": "^8.4.38",
|
|
90
|
+
"prettier": "3.3.1",
|
|
91
|
+
"storybook": "^8.6.15",
|
|
92
|
+
"storybook-vue3-router": "^5.0.0",
|
|
93
|
+
"tailwind-config-viewer": "^2.0.2",
|
|
94
|
+
"tailwindcss": "^3.4.4",
|
|
95
|
+
"typescript": "~5.3.3",
|
|
96
|
+
"typescript-eslint": "^7.17.0",
|
|
97
|
+
"unplugin-vue-components": "^0.27.0",
|
|
98
|
+
"vite": "^5.2.0",
|
|
99
|
+
"vite-plugin-css-injected-by-js": "^3.5.1",
|
|
100
|
+
"vite-plugin-static-copy": "^1.0.6",
|
|
101
|
+
"vue-eslint-parser": "^9.4.3",
|
|
102
|
+
"vue-router": "^4.4.3",
|
|
103
|
+
"vue-tsc": "^2.0.29"
|
|
104
|
+
},
|
|
105
|
+
"peerDependencies": {
|
|
106
|
+
"graphql-tag": "^2.12.6",
|
|
107
|
+
"vue": "^3.0.0"
|
|
108
|
+
},
|
|
109
|
+
"lint-staged": {
|
|
110
|
+
"*.{json,js,ts,jsx,tsx,html,vue}": [
|
|
111
|
+
"prettier --write --ignore-unknown"
|
|
112
|
+
]
|
|
113
|
+
}
|
|
114
|
+
}
|