@berdsk/ui 0.0.1
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/README.md +0 -0
- package/dist/index.cjs +2 -0
- package/dist/index.cjs.map +1 -0
- package/dist/index.d.cts +8 -0
- package/dist/index.d.ts +8 -0
- package/dist/index.js +2 -0
- package/dist/index.js.map +1 -0
- package/package.json +48 -0
package/README.md
ADDED
|
Binary file
|
package/dist/index.cjs
ADDED
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
"use strict";var l=Object.create;var o=Object.defineProperty;var f=Object.getOwnPropertyDescriptor;var m=Object.getOwnPropertyNames;var p=Object.getPrototypeOf,u=Object.prototype.hasOwnProperty;var k=(e,t)=>{for(var n in t)o(e,n,{get:t[n],enumerable:!0})},r=(e,t,n,s)=>{if(t&&typeof t=="object"||typeof t=="function")for(let c of m(t))!u.call(e,c)&&c!==n&&o(e,c,{get:()=>t[c],enumerable:!(s=f(t,c))||s.enumerable});return e};var h=(e,t,n)=>(n=e!=null?l(p(e)):{},r(t||!e||!e.__esModule?o(n,"default",{value:e,enumerable:!0}):n,e)),x=e=>r(o({},"__esModule",{value:!0}),e);var b={};k(b,{Icon:()=>R});module.exports=x(b);var a=h(require("react"),1),d=require("react/jsx-runtime"),i="https://cdn.berdsk.com.br/berdsk-ui/icons/all.css",L=()=>{if(typeof document>"u")return;if(!document.querySelector(`link[href="${i}"]`)){let t=document.createElement("link");t.rel="stylesheet",t.href=i,document.head.appendChild(t)}},R=({className:e,...t})=>(a.useEffect(()=>{L()},[]),(0,d.jsx)("i",{className:`${e}`,...t}));0&&(module.exports={Icon});
|
|
2
|
+
//# sourceMappingURL=index.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/index.ts","../src/components/Icon.tsx"],"sourcesContent":["\r\nexport * from './components/Icon';\r\n","import * as React from \"react\";\r\n\r\nconst CDN_URL = \"https://cdn.berdsk.com.br/berdsk-ui/icons/all.css\";\r\n\r\nexport interface IconProps extends React.HTMLAttributes<HTMLElement> {\r\n className: string;\r\n}\r\n\r\nconst loadCDN = () => {\r\n if (typeof document === \"undefined\") return;\r\n\r\n const existingLink = document.querySelector(`link[href=\"${CDN_URL}\"]`);\r\n if (!existingLink) {\r\n const link = document.createElement(\"link\");\r\n link.rel = \"stylesheet\";\r\n link.href = CDN_URL;\r\n document.head.appendChild(link);\r\n }\r\n};\r\n\r\nexport const Icon: React.FC<IconProps> = ({ className, ...props }) => {\r\n React.useEffect(() => {\r\n loadCDN();\r\n }, []);\r\n\r\n return <i className={`${className}`} {...props} />;\r\n};\r\n\r\n"],"mappings":"0jBAAA,IAAAA,EAAA,GAAAC,EAAAD,EAAA,UAAAE,IAAA,eAAAC,EAAAH,GCAA,IAAAI,EAAuB,sBAyBdC,EAAA,6BAvBHC,EAAU,oDAMVC,EAAU,IAAM,CACpB,GAAI,OAAO,SAAa,IAAa,OAGrC,GAAI,CADiB,SAAS,cAAc,cAAcD,CAAO,IAAI,EAClD,CACjB,IAAME,EAAO,SAAS,cAAc,MAAM,EAC1CA,EAAK,IAAM,aACXA,EAAK,KAAOF,EACZ,SAAS,KAAK,YAAYE,CAAI,CAChC,CACF,EAEaC,EAA4B,CAAC,CAAE,UAAAC,EAAW,GAAGC,CAAM,KACxD,YAAU,IAAM,CACpBJ,EAAQ,CACV,EAAG,CAAC,CAAC,KAEE,OAAC,KAAE,UAAW,GAAGG,CAAS,GAAK,GAAGC,EAAO","names":["index_exports","__export","Icon","__toCommonJS","React","import_jsx_runtime","CDN_URL","loadCDN","link","Icon","className","props"]}
|
package/dist/index.d.cts
ADDED
package/dist/index.d.ts
ADDED
package/dist/index.js
ADDED
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import*as c from"react";import{jsx as s}from"react/jsx-runtime";var n="https://cdn.berdsk.com.br/berdsk-ui/icons/all.css",o=()=>{if(typeof document>"u")return;if(!document.querySelector(`link[href="${n}"]`)){let e=document.createElement("link");e.rel="stylesheet",e.href=n,document.head.appendChild(e)}},r=({className:t,...e})=>(c.useEffect(()=>{o()},[]),s("i",{className:`${t}`,...e}));export{r as Icon};
|
|
2
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/components/Icon.tsx"],"sourcesContent":["import * as React from \"react\";\r\n\r\nconst CDN_URL = \"https://cdn.berdsk.com.br/berdsk-ui/icons/all.css\";\r\n\r\nexport interface IconProps extends React.HTMLAttributes<HTMLElement> {\r\n className: string;\r\n}\r\n\r\nconst loadCDN = () => {\r\n if (typeof document === \"undefined\") return;\r\n\r\n const existingLink = document.querySelector(`link[href=\"${CDN_URL}\"]`);\r\n if (!existingLink) {\r\n const link = document.createElement(\"link\");\r\n link.rel = \"stylesheet\";\r\n link.href = CDN_URL;\r\n document.head.appendChild(link);\r\n }\r\n};\r\n\r\nexport const Icon: React.FC<IconProps> = ({ className, ...props }) => {\r\n React.useEffect(() => {\r\n loadCDN();\r\n }, []);\r\n\r\n return <i className={`${className}`} {...props} />;\r\n};\r\n\r\n"],"mappings":"AAAA,UAAYA,MAAW,QAyBd,cAAAC,MAAA,oBAvBT,IAAMC,EAAU,oDAMVC,EAAU,IAAM,CACpB,GAAI,OAAO,SAAa,IAAa,OAGrC,GAAI,CADiB,SAAS,cAAc,cAAcD,CAAO,IAAI,EAClD,CACjB,IAAME,EAAO,SAAS,cAAc,MAAM,EAC1CA,EAAK,IAAM,aACXA,EAAK,KAAOF,EACZ,SAAS,KAAK,YAAYE,CAAI,CAChC,CACF,EAEaC,EAA4B,CAAC,CAAE,UAAAC,EAAW,GAAGC,CAAM,KACxD,YAAU,IAAM,CACpBJ,EAAQ,CACV,EAAG,CAAC,CAAC,EAEEF,EAAC,KAAE,UAAW,GAAGK,CAAS,GAAK,GAAGC,EAAO","names":["React","jsx","CDN_URL","loadCDN","link","Icon","className","props"]}
|
package/package.json
ADDED
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@berdsk/ui",
|
|
3
|
+
"version": "0.0.1",
|
|
4
|
+
"description": "Biblioteca de componentes UI profissional da Berdsk",
|
|
5
|
+
"author": "Berdsk",
|
|
6
|
+
"publishConfig": {
|
|
7
|
+
"access": "public"
|
|
8
|
+
},
|
|
9
|
+
"license": "MIT",
|
|
10
|
+
"keywords": [],
|
|
11
|
+
"sideEffects": false,
|
|
12
|
+
"type": "module",
|
|
13
|
+
"main": "./dist/index.cjs",
|
|
14
|
+
"module": "./dist/index.js",
|
|
15
|
+
"types": "./dist/index.d.ts",
|
|
16
|
+
"exports": {
|
|
17
|
+
".": {
|
|
18
|
+
"types": "./dist/index.d.ts",
|
|
19
|
+
"import": "./dist/index.js",
|
|
20
|
+
"require": "./dist/index.cjs"
|
|
21
|
+
}
|
|
22
|
+
},
|
|
23
|
+
"files": [
|
|
24
|
+
"dist"
|
|
25
|
+
],
|
|
26
|
+
"engines": {
|
|
27
|
+
"node": ">=18"
|
|
28
|
+
},
|
|
29
|
+
"scripts": {
|
|
30
|
+
"build": "tsup",
|
|
31
|
+
"clean": "rimraf dist",
|
|
32
|
+
"prepublishOnly": "npm run build",
|
|
33
|
+
"dev": "tsup --watch"
|
|
34
|
+
},
|
|
35
|
+
"peerDependencies": {
|
|
36
|
+
"react": ">=18",
|
|
37
|
+
"react-dom": ">=18"
|
|
38
|
+
},
|
|
39
|
+
"devDependencies": {
|
|
40
|
+
"@types/react": "^19.2.14",
|
|
41
|
+
"@types/react-dom": "^19.2.0",
|
|
42
|
+
"react": "^19.2.4",
|
|
43
|
+
"react-dom": "^19.2.4",
|
|
44
|
+
"tsup": "^8.5.1",
|
|
45
|
+
"typescript": "^5.9.3",
|
|
46
|
+
"rimraf": "^5.0.0"
|
|
47
|
+
}
|
|
48
|
+
}
|