@jasonshimmy/custom-elements-runtime 0.0.14 → 0.0.16

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/runtime.d.ts CHANGED
@@ -33,7 +33,6 @@ export interface ComponentConfig<S extends object, C extends object = {}, P exte
33
33
  }>;
34
34
  watch?: WatchConfig<ComponentContext<S, C, P, T>>;
35
35
  style?: string | ((context: ComponentContext<S, C, P, T>) => string);
36
- minifyCSS?: boolean;
37
36
  render: (context: ComponentContext<S, C, P, T>) => VNode | VNode[] | Promise<VNode | VNode[]>;
38
37
  loadingTemplate?: (context: ComponentContext<S, C, P, T>) => VNode | VNode[];
39
38
  errorTemplate?: (error: Error, context: ComponentContext<S, C, P, T>) => VNode | VNode[];
@@ -2,8 +2,10 @@
2
2
  * CSS minification utility (basic)
3
3
  */
4
4
  export declare function minifyCSS(css: string): string;
5
+ export declare function getBaseResetSheet(): CSSStyleSheet;
6
+ export declare function sanitizeCSS(css: string): string;
5
7
  /**
6
8
  * Minimal Shadow DOM reset
7
9
  */
8
- export declare const baseReset = "\n :host {\n box-sizing:border-box;\n line-height:1.5;\n font-family:ui-sans-serif,system-ui,sans-serif;\n -webkit-text-size-adjust:100%;\n text-size-adjust:100%;\n }\n *,::before,::after {\n box-sizing:inherit;\n margin:0;\n padding:0;\n border:0 solid currentColor;\n }\n";
10
+ export declare const baseReset = "\n :host, *, ::before, ::after {\n box-sizing: border-box;\n border-width: 0;\n border-style: solid;\n border-color: currentColor;\n }\n :host {\n font-size: 16px;\n line-height: 1.5;\n font-family: ui-sans-serif, system-ui, sans-serif;\n -webkit-text-size-adjust: 100%;\n text-size-adjust: 100%;\n color: inherit;\n background-color: transparent;\n }\n *, ::before, ::after {\n -webkit-tap-highlight-color: transparent;\n margin: 0;\n padding: 0;\n font: inherit;\n vertical-align: baseline;\n background: transparent;\n color: inherit;\n }\n button, input, optgroup, select, textarea {\n font: inherit;\n color: inherit;\n background: transparent;\n border: none;\n outline: none;\n margin: 0;\n padding: 0;\n }\n textarea {\n resize: vertical;\n }\n progress {\n vertical-align: baseline;\n }\n button, textarea {\n overflow: visible;\n }\n input[type=\"search\"]::-webkit-search-decoration,\n input[type=\"search\"]::-webkit-search-cancel-button,\n input[type=\"search\"]::-webkit-search-results-button,\n input[type=\"search\"]::-webkit-search-results-decoration {\n -webkit-appearance: none;\n }\n img, svg, video, canvas, audio, iframe, embed, object {\n display: block;\n max-width: 100%;\n height: auto;\n vertical-align: middle;\n }\n select {\n text-transform: none;\n }\n optgroup {\n font-weight: bold;\n }\n fieldset {\n border: none;\n }\n svg {\n fill: currentColor;\n stroke: none;\n }\n a {\n color: inherit;\n text-decoration: inherit;\n }\n a, button {\n cursor: pointer;\n }\n input[type=\"file\"] {\n border: 0;\n }\n button, [type=\"button\"], [type=\"reset\"], [type=\"submit\"] {\n appearance: button;\n background-color: transparent;\n background-image: none;\n }\n [type='button'], [type='reset'], [type='submit'] {\n -webkit-user-select: none;\n user-select: none;\n }\n ::-webkit-input-placeholder { color: inherit; opacity: 0.5; }\n ::placeholder { color: inherit; opacity: 0.5; }\n *:focus {\n outline: 2px solid #3b82f6;\n outline-offset: 2px;\n }\n ol, ul {\n list-style: none;\n }\n table {\n border-collapse: collapse;\n border-spacing: 0;\n }\n strong {\n font-weight: bolder;\n }\n sub, sup {\n font-size: 0.75em;\n line-height: 0;\n position: relative;\n vertical-align: baseline;\n }\n sub {\n bottom: -0.25em;\n }\n sup {\n top: -0.5em;\n }\n [disabled] {\n cursor: not-allowed;\n }\n [hidden] {\n display: none;\n }\n [aria-disabled=\"true\"] {\n cursor: not-allowed;\n }\n";
9
11
  export declare function jitCSS(html: string): string;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@jasonshimmy/custom-elements-runtime",
3
3
  "description": "A powerful, modern, and lightweight runtime for creating reactive web components with TypeScript",
4
- "version": "0.0.14",
4
+ "version": "0.0.16",
5
5
  "type": "module",
6
6
  "keywords": [
7
7
  "web-components",