@pikacss/core 0.0.21 → 0.0.23

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.cjs CHANGED
@@ -1,7 +1,7 @@
1
1
  'use strict';
2
2
 
3
- const ATOMIC_STYLE_ID_PLACEHOLDER = "$$";
4
- const ATOMIC_STYLE_ID_PLACEHOLDER_RE_GLOBAL = /\$\$/g;
3
+ const ATOMIC_STYLE_ID_PLACEHOLDER = "%";
4
+ const ATOMIC_STYLE_ID_PLACEHOLDER_RE_GLOBAL = /%/g;
5
5
 
6
6
  let _warn = (...args) => {
7
7
  console.warn("[@pikacss/core]", ...args);
@@ -326,7 +326,7 @@ function keyframes() {
326
326
  }
327
327
  });
328
328
  return renderCSSStyleBlocks(
329
- new Map(Array.from(engine2.keyframes.store.entries()).filter(([name]) => used.has(name)).map(([name, frames]) => [
329
+ new Map(Array.from(engine2.keyframes.store.entries()).filter(([name, { pruneUnused }]) => pruneUnused === false || used.has(name)).map(([name, { frames }]) => [
330
330
  `@keyframes ${name}`,
331
331
  {
332
332
  properties: [],
@@ -735,7 +735,7 @@ function variables() {
735
735
  /* @__PURE__ */ new Map([[
736
736
  ":root",
737
737
  {
738
- properties: Array.from(engine2.variables.store.entries()).filter(([name, { value }]) => used.has(name) && value != null).map(([name, { value }]) => ({ property: name, value }))
738
+ properties: Array.from(engine2.variables.store.entries()).filter(([name, { pruneUnused, value }]) => (pruneUnused === false || used.has(name)) && value != null).map(([name, { value }]) => ({ property: name, value }))
739
739
  }
740
740
  ]]),
741
741
  isFormatted
package/dist/index.d.cts CHANGED
@@ -395,15 +395,15 @@ interface EngineConfig {
395
395
  */
396
396
  prefix?: string;
397
397
  /**
398
- * Set the default selector format. '$$' will be replaced with the atomic style id.
398
+ * Set the default selector format. '%' will be replaced with the atomic style id.
399
399
  *
400
- * @default '.$$'
400
+ * @default '.%'
401
401
  * @example
402
402
  * ```ts
403
403
  * {
404
- * defaultSelector: '.$$' // Use with class attribute: <div class="a b c">
404
+ * defaultSelector: '.%' // Use with class attribute: <div class="a b c">
405
405
  * // or
406
- * defaultSelector: '[data-pika~="$$"]' // Use with attribute selector: <div data-pika="a b c">
406
+ * defaultSelector: '[data-pika~="%"]' // Use with attribute selector: <div data-pika="a b c">
407
407
  * }
408
408
  * ```
409
409
  */
package/dist/index.d.mts CHANGED
@@ -395,15 +395,15 @@ interface EngineConfig {
395
395
  */
396
396
  prefix?: string;
397
397
  /**
398
- * Set the default selector format. '$$' will be replaced with the atomic style id.
398
+ * Set the default selector format. '%' will be replaced with the atomic style id.
399
399
  *
400
- * @default '.$$'
400
+ * @default '.%'
401
401
  * @example
402
402
  * ```ts
403
403
  * {
404
- * defaultSelector: '.$$' // Use with class attribute: <div class="a b c">
404
+ * defaultSelector: '.%' // Use with class attribute: <div class="a b c">
405
405
  * // or
406
- * defaultSelector: '[data-pika~="$$"]' // Use with attribute selector: <div data-pika="a b c">
406
+ * defaultSelector: '[data-pika~="%"]' // Use with attribute selector: <div data-pika="a b c">
407
407
  * }
408
408
  * ```
409
409
  */
package/dist/index.d.ts CHANGED
@@ -395,15 +395,15 @@ interface EngineConfig {
395
395
  */
396
396
  prefix?: string;
397
397
  /**
398
- * Set the default selector format. '$$' will be replaced with the atomic style id.
398
+ * Set the default selector format. '%' will be replaced with the atomic style id.
399
399
  *
400
- * @default '.$$'
400
+ * @default '.%'
401
401
  * @example
402
402
  * ```ts
403
403
  * {
404
- * defaultSelector: '.$$' // Use with class attribute: <div class="a b c">
404
+ * defaultSelector: '.%' // Use with class attribute: <div class="a b c">
405
405
  * // or
406
- * defaultSelector: '[data-pika~="$$"]' // Use with attribute selector: <div data-pika="a b c">
406
+ * defaultSelector: '[data-pika~="%"]' // Use with attribute selector: <div data-pika="a b c">
407
407
  * }
408
408
  * ```
409
409
  */
package/dist/index.mjs CHANGED
@@ -1,5 +1,5 @@
1
- const ATOMIC_STYLE_ID_PLACEHOLDER = "$$";
2
- const ATOMIC_STYLE_ID_PLACEHOLDER_RE_GLOBAL = /\$\$/g;
1
+ const ATOMIC_STYLE_ID_PLACEHOLDER = "%";
2
+ const ATOMIC_STYLE_ID_PLACEHOLDER_RE_GLOBAL = /%/g;
3
3
 
4
4
  let _warn = (...args) => {
5
5
  console.warn("[@pikacss/core]", ...args);
@@ -324,7 +324,7 @@ function keyframes() {
324
324
  }
325
325
  });
326
326
  return renderCSSStyleBlocks(
327
- new Map(Array.from(engine2.keyframes.store.entries()).filter(([name]) => used.has(name)).map(([name, frames]) => [
327
+ new Map(Array.from(engine2.keyframes.store.entries()).filter(([name, { pruneUnused }]) => pruneUnused === false || used.has(name)).map(([name, { frames }]) => [
328
328
  `@keyframes ${name}`,
329
329
  {
330
330
  properties: [],
@@ -733,7 +733,7 @@ function variables() {
733
733
  /* @__PURE__ */ new Map([[
734
734
  ":root",
735
735
  {
736
- properties: Array.from(engine2.variables.store.entries()).filter(([name, { value }]) => used.has(name) && value != null).map(([name, { value }]) => ({ property: name, value }))
736
+ properties: Array.from(engine2.variables.store.entries()).filter(([name, { pruneUnused, value }]) => (pruneUnused === false || used.has(name)) && value != null).map(([name, { value }]) => ({ property: name, value }))
737
737
  }
738
738
  ]]),
739
739
  isFormatted
package/package.json CHANGED
@@ -4,7 +4,7 @@
4
4
  "publishConfig": {
5
5
  "access": "public"
6
6
  },
7
- "version": "0.0.21",
7
+ "version": "0.0.23",
8
8
  "author": "DevilTea <ch19980814@gmail.com>",
9
9
  "license": "MIT",
10
10
  "repository": {