daisyui 3.9.0 → 3.9.2
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/package.json +5 -23
- package/src/index.js +26 -38
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "daisyui",
|
|
3
|
-
"version": "3.9.
|
|
3
|
+
"version": "3.9.2",
|
|
4
4
|
"description": "daisyUI - Tailwind CSS Components",
|
|
5
5
|
"author": "Pouya Saadeghi",
|
|
6
6
|
"license": "MIT",
|
|
@@ -24,6 +24,7 @@
|
|
|
24
24
|
"component",
|
|
25
25
|
"framework",
|
|
26
26
|
"tailwind",
|
|
27
|
+
"daisyui",
|
|
27
28
|
"theming",
|
|
28
29
|
"postcss",
|
|
29
30
|
"design",
|
|
@@ -56,29 +57,10 @@
|
|
|
56
57
|
]
|
|
57
58
|
},
|
|
58
59
|
"scripts": {
|
|
59
|
-
"init": "npm install && npm run build && cd src/docs && npm
|
|
60
|
+
"init": "npm install && npm run build && cd src/docs && npm install && cd src/experiments/playground && npm install",
|
|
60
61
|
"prettier": "prettier --write '**/*.{js,svelte,md,json,html,css}' --config src/.prettierrc.yaml --ignore-path src/.prettierignore",
|
|
61
|
-
"
|
|
62
|
-
"
|
|
63
|
-
"postbase": "prejss-cli dist/base.css --format commonjs",
|
|
64
|
-
"preutilities:global": "postcss --config src/utilities/global src/utilities/global/*.css --base src --dir dist",
|
|
65
|
-
"utilities:global": "cat dist/utilities/global/*.css > dist/utilities.css",
|
|
66
|
-
"postutilities:global": "prejss-cli dist/utilities.css --format commonjs",
|
|
67
|
-
"preutilities:unstyled": "postcss --config src/utilities/unstyled src/utilities/unstyled/*.css --base src --dir dist",
|
|
68
|
-
"utilities:unstyled": "cat dist/utilities/unstyled/*.css > dist/utilities-unstyled.css",
|
|
69
|
-
"postutilities:unstyled": "prejss-cli dist/utilities-unstyled.css --format commonjs",
|
|
70
|
-
"preutilities:styled": "postcss --config src/utilities/styled src/utilities/styled/*.css --base src --dir dist",
|
|
71
|
-
"utilities:styled": "cat dist/utilities/styled/*.css > dist/utilities-styled.css",
|
|
72
|
-
"postutilities:styled": "prejss-cli dist/utilities-styled.css --format commonjs",
|
|
73
|
-
"components": "postcss --config src/components src/components/**/*.css --base src --dir dist",
|
|
74
|
-
"merge:unstyled": "cat dist/components/unstyled/*.css > dist/unstyled.css",
|
|
75
|
-
"merge:styled": "cat dist/components/unstyled/*.css dist/components/styled/*.css > dist/styled.css",
|
|
76
|
-
"rtl": "rtlcss dist/unstyled.css -s && rtlcss dist/styled.css -s",
|
|
77
|
-
"prejss": "prejss-cli dist/{unstyled,styled}{,.rtl}.css --format commonjs",
|
|
78
|
-
"themes": "postcss src/themes/index.css -o dist/themes.css --config src/themes",
|
|
79
|
-
"full": "postcss src/full/index.css -o dist/full.css --config src/full",
|
|
80
|
-
"build": "npm run base && npm run utilities:global && npm run utilities:unstyled && npm run utilities:styled && npm run components && npm run merge:unstyled && npm run merge:styled && npm run rtl && npm run prejss && npm run themes && npm run full",
|
|
81
|
-
"build:skipcdnfiles": "npm run base && npm run utilities:global && npm run utilities:unstyled && npm run utilities:styled && npm run components && npm run merge:unstyled && npm run merge:styled && npm run rtl && npm run prejss && npm run themes",
|
|
62
|
+
"build": "node src/build",
|
|
63
|
+
"build:skipfullcss": "node src/build --skipfullcss",
|
|
82
64
|
"dev": "cd src/docs && npm run dev",
|
|
83
65
|
"add": "touch src/components/unstyled/$npm_config_name.css && touch src/components/styled/$npm_config_name.css",
|
|
84
66
|
"postadd": "open src/components/unstyled/$npm_config_name.css && open src/components/styled/$npm_config_name.css",
|
package/src/index.js
CHANGED
|
@@ -23,11 +23,7 @@ const mainFunction = ({ addBase, addComponents, config }) => {
|
|
|
23
23
|
}
|
|
24
24
|
if (logs) {
|
|
25
25
|
console.log()
|
|
26
|
-
console.log(
|
|
27
|
-
"\x1b[35m%s\x1b[0m",
|
|
28
|
-
"🌼 daisyUI " + daisyuiInfo.version,
|
|
29
|
-
"\x1b[0m" + daisyuiInfo.homepage
|
|
30
|
-
)
|
|
26
|
+
console.log("╭── 🌼\x1b[35m daisyUI " + daisyuiInfo.version, "\x1b[0m" + daisyuiInfo.homepage)
|
|
31
27
|
}
|
|
32
28
|
|
|
33
29
|
// inject @base style
|
|
@@ -86,80 +82,72 @@ const mainFunction = ({ addBase, addComponents, config }) => {
|
|
|
86
82
|
}
|
|
87
83
|
|
|
88
84
|
if (logs) {
|
|
89
|
-
console.log("
|
|
85
|
+
console.log("│")
|
|
90
86
|
if (config("daisyui.styled") == false) {
|
|
91
87
|
console.log(
|
|
92
|
-
"
|
|
93
|
-
"\x1b[33m" + "◆" + "\x1b[0m" + "\x1b[2m",
|
|
88
|
+
"├──",
|
|
94
89
|
"daisyui.styled",
|
|
95
90
|
"\x1b[0m" + "config is",
|
|
96
91
|
"\x1b[2m" + "false" + "\x1b[0m",
|
|
97
|
-
"– your components will have no design decisions" + "\n
|
|
92
|
+
"– your components will have no design decisions" + "\n│"
|
|
98
93
|
)
|
|
99
94
|
}
|
|
100
95
|
if (config("daisyui.utils") == false) {
|
|
101
96
|
console.log(
|
|
102
|
-
"
|
|
103
|
-
"\x1b[33m" + "◆" + "\x1b[0m" + "\x1b[2m",
|
|
97
|
+
"├──",
|
|
104
98
|
"daisyui.utils",
|
|
105
99
|
"\x1b[0m" + "config is",
|
|
106
100
|
"\x1b[2m" + "false" + "\x1b[0m",
|
|
107
|
-
"– daisyUI modifier utility classes are disabled" + "\n
|
|
101
|
+
"– daisyUI modifier utility classes are disabled" + "\n│"
|
|
108
102
|
)
|
|
109
103
|
}
|
|
110
104
|
if (config("daisyui.prefix") && config("daisyui.prefix") !== "") {
|
|
111
105
|
console.log(
|
|
112
|
-
"
|
|
113
|
-
"\x1b[
|
|
114
|
-
"
|
|
106
|
+
"├──",
|
|
107
|
+
"\x1b[2m" + "prefix" + "\x1b[0m",
|
|
108
|
+
"is enabled, daisyUI classnames must use",
|
|
115
109
|
"\x1b[2m" + `${config("daisyui.prefix")}`,
|
|
116
110
|
"\x1b[0m" + "prefix. like:",
|
|
117
111
|
"\x1b[2m" + `${config("daisyui.prefix")}btn`,
|
|
118
|
-
"\x1b[0m" + "\n
|
|
112
|
+
"\x1b[0m" + "\n│ https://daisyui.com/docs/config" + "\n│"
|
|
119
113
|
)
|
|
120
114
|
}
|
|
121
115
|
if (config("daisyui.rtl") == true) {
|
|
122
116
|
console.log(
|
|
123
|
-
"
|
|
124
|
-
"\x1b[32m" + "✔︎" + "\x1b[0m",
|
|
117
|
+
"├──",
|
|
125
118
|
"Using RTL, make sure you're using",
|
|
126
119
|
"\x1b[2m" + "<html dir=rtl>" + "\x1b[0m",
|
|
127
120
|
"and you have",
|
|
128
|
-
"\x1b[
|
|
129
|
-
"tailwindcss-flip",
|
|
130
|
-
"\x1b[0m",
|
|
121
|
+
"\x1b[2mtailwindcss-flip\x1b[0m",
|
|
131
122
|
"plugin",
|
|
132
|
-
"\n
|
|
123
|
+
"\n│ https://daisyui.com/docs/config" + "\n│"
|
|
133
124
|
)
|
|
134
125
|
}
|
|
135
126
|
if (themeInjectorHsl.themeOrder.length > 0) {
|
|
136
127
|
console.log(
|
|
137
|
-
"
|
|
138
|
-
"\x1b[32m" + "✔︎" + "\x1b[0m",
|
|
128
|
+
"├──",
|
|
139
129
|
"\x1b[2m" +
|
|
140
|
-
"[ " +
|
|
141
|
-
"\x1b[0m" +
|
|
142
130
|
`${themeInjectorHsl.themeOrder.length}` +
|
|
143
|
-
"\x1b[2m" +
|
|
144
|
-
" ]" +
|
|
145
131
|
"\x1b[0m" +
|
|
146
132
|
` ${themeInjectorHsl.themeOrder.length > 1 ? "themes are" : "theme is"}` +
|
|
147
|
-
` enabled.
|
|
148
|
-
"\n
|
|
133
|
+
` enabled. How to add more themes:` +
|
|
134
|
+
"\n│ https://daisyui.com/docs/themes" +
|
|
135
|
+
"\n│"
|
|
149
136
|
)
|
|
150
137
|
}
|
|
151
138
|
if (themeInjectorHsl.themeOrder.length === 0) {
|
|
152
139
|
console.log(
|
|
153
|
-
"
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
"\n
|
|
140
|
+
"├──",
|
|
141
|
+
`All themes are disabled in config. How to add themes:` +
|
|
142
|
+
"\n│ https://daisyui.com/docs/themes" +
|
|
143
|
+
"\n│"
|
|
157
144
|
)
|
|
158
145
|
}
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
146
|
+
let messages = [
|
|
147
|
+
`\x1b[32m💚 Support daisyUI project\x1b[0m: ${daisyuiInfo.funding.url}`,
|
|
148
|
+
`\x1b[32m⭐️ Star daisyUI project on GitHub\x1b[0m: https://github.com/saadeghi/daisyui`,
|
|
149
|
+
]
|
|
150
|
+
console.log("╰── " + messages[Math.floor(Math.random() * messages.length)])
|
|
163
151
|
console.log()
|
|
164
152
|
}
|
|
165
153
|
}
|