@pandacss/shared 0.0.0-dev-20221203082644 → 0.0.0-dev-20221203144844

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/index.js CHANGED
@@ -208,6 +208,7 @@ var fallbackCondition = {
208
208
  finalize: (v) => v,
209
209
  breakpoints: { keys: [] }
210
210
  };
211
+ var sanitize = (value) => typeof value === "string" ? value.replaceAll(/[\n\s]+/g, " ") : value;
211
212
  function createCss(context) {
212
213
  const { utility, hash, conditions: conds = fallbackCondition } = context;
213
214
  return (styleObject = {}) => {
@@ -220,7 +221,7 @@ function createCss(context) {
220
221
  return;
221
222
  const [prop, ...allConditions] = conds.shift(paths);
222
223
  const conditions = filterBaseConditions(allConditions);
223
- const transformed = utility.transform(prop, withoutImportant(value));
224
+ const transformed = utility.transform(prop, withoutImportant(sanitize(value)));
224
225
  let transformedClassName = transformed.className;
225
226
  if (important) {
226
227
  transformedClassName = `${transformedClassName}!`;
package/dist/index.mjs CHANGED
@@ -150,6 +150,7 @@ var fallbackCondition = {
150
150
  finalize: (v) => v,
151
151
  breakpoints: { keys: [] }
152
152
  };
153
+ var sanitize = (value) => typeof value === "string" ? value.replaceAll(/[\n\s]+/g, " ") : value;
153
154
  function createCss(context) {
154
155
  const { utility, hash, conditions: conds = fallbackCondition } = context;
155
156
  return (styleObject = {}) => {
@@ -162,7 +163,7 @@ function createCss(context) {
162
163
  return;
163
164
  const [prop, ...allConditions] = conds.shift(paths);
164
165
  const conditions = filterBaseConditions(allConditions);
165
- const transformed = utility.transform(prop, withoutImportant(value));
166
+ const transformed = utility.transform(prop, withoutImportant(sanitize(value)));
166
167
  let transformedClassName = transformed.className;
167
168
  if (important) {
168
169
  transformedClassName = `${transformedClassName}!`;
package/dist/shared.js CHANGED
@@ -157,6 +157,7 @@ var fallbackCondition = {
157
157
  finalize: (v) => v,
158
158
  breakpoints: { keys: [] }
159
159
  };
160
+ var sanitize = (value) => typeof value === "string" ? value.replaceAll(/[\n\s]+/g, " ") : value;
160
161
  function createCss(context) {
161
162
  const { utility, hash, conditions: conds = fallbackCondition } = context;
162
163
  return (styleObject = {}) => {
@@ -169,7 +170,7 @@ function createCss(context) {
169
170
  return;
170
171
  const [prop, ...allConditions] = conds.shift(paths);
171
172
  const conditions = filterBaseConditions(allConditions);
172
- const transformed = utility.transform(prop, withoutImportant(value));
173
+ const transformed = utility.transform(prop, withoutImportant(sanitize(value)));
173
174
  let transformedClassName = transformed.className;
174
175
  if (important) {
175
176
  transformedClassName = `${transformedClassName}!`;
package/dist/shared.mjs CHANGED
@@ -124,6 +124,7 @@ var fallbackCondition = {
124
124
  finalize: (v) => v,
125
125
  breakpoints: { keys: [] }
126
126
  };
127
+ var sanitize = (value) => typeof value === "string" ? value.replaceAll(/[\n\s]+/g, " ") : value;
127
128
  function createCss(context) {
128
129
  const { utility, hash, conditions: conds = fallbackCondition } = context;
129
130
  return (styleObject = {}) => {
@@ -136,7 +137,7 @@ function createCss(context) {
136
137
  return;
137
138
  const [prop, ...allConditions] = conds.shift(paths);
138
139
  const conditions = filterBaseConditions(allConditions);
139
- const transformed = utility.transform(prop, withoutImportant(value));
140
+ const transformed = utility.transform(prop, withoutImportant(sanitize(value)));
140
141
  let transformedClassName = transformed.className;
141
142
  if (important) {
142
143
  transformedClassName = `${transformedClassName}!`;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pandacss/shared",
3
- "version": "0.0.0-dev-20221203082644",
3
+ "version": "0.0.0-dev-20221203144844",
4
4
  "description": "Shared utilities for css panda",
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/index.mjs",