@anker-in/headless-ui 0.0.27-alpha.34 → 0.0.27-alpha.36

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.
@@ -1,2 +1,2 @@
1
- "use strict";"use client";var f=Object.create;var a=Object.defineProperty;var C=Object.getOwnPropertyDescriptor;var u=Object.getOwnPropertyNames;var h=Object.getPrototypeOf,k=Object.prototype.hasOwnProperty;var v=(e,t)=>{for(var o in t)a(e,o,{get:t[o],enumerable:!0})},d=(e,t,o,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let p of u(t))!k.call(e,p)&&p!==o&&a(e,p,{get:()=>t[p],enumerable:!(n=C(t,p))||n.enumerable});return e};var b=(e,t,o)=>(o=e!=null?f(h(e)):{},d(t||!e||!e.__esModule?a(o,"default",{value:e,enumerable:!0}):o,e)),w=e=>d(a({},"__esModule",{value:!0}),e);var N={};v(N,{Container:()=>s});module.exports=w(N);var m=require("react/jsx-runtime"),r=b(require("react")),l=require("../helpers/utils.js"),c=require("@radix-ui/react-slot");const s=r.default.forwardRef(({...e},t)=>{const{asChild:o,children:n,className:p,overflow:y,...x}=e,i=o?c.Slot:"div";return(0,r.useMemo)(()=>y==="hidden"?(0,m.jsx)("div",{className:(0,l.cn)("overflow-hidden","tablet:my-[80px] laptop:my-[96px] desktop:my-[112px] lg-desktop:my-[128px] my-[64px]",p),children:(0,m.jsx)(i,{className:(0,l.cn)("mx-auto box-content w-full max-w-[1664px]","tablet:px-8 laptop:px-16 desktop:px-16 lg-desktop:px-32 px-8"),...x,ref:t,children:n})}):(0,m.jsx)(i,{...x,ref:t,className:(0,l.cn)("mx-auto box-content w-full max-w-[1664px]","tablet:px-8 laptop:px-16 desktop:px-16 lg-desktop:px-32 px-8","tablet:my-[80px] laptop:my-[96px] desktop:my-[112px] lg-desktop:my-[128px] my-[64px]",p),children:n}),[e])});s.displayName="Container";
1
+ "use strict";"use client";var f=Object.create;var a=Object.defineProperty;var C=Object.getOwnPropertyDescriptor;var u=Object.getOwnPropertyNames;var b=Object.getPrototypeOf,h=Object.prototype.hasOwnProperty;var k=(e,t)=>{for(var o in t)a(e,o,{get:t[o],enumerable:!0})},d=(e,t,o,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let p of u(t))!h.call(e,p)&&p!==o&&a(e,p,{get:()=>t[p],enumerable:!(n=C(t,p))||n.enumerable});return e};var v=(e,t,o)=>(o=e!=null?f(b(e)):{},d(t||!e||!e.__esModule?a(o,"default",{value:e,enumerable:!0}):o,e)),w=e=>d(a({},"__esModule",{value:!0}),e);var N={};k(N,{Container:()=>s});module.exports=w(N);var r=require("react/jsx-runtime"),m=v(require("react")),l=require("../helpers/utils.js"),c=require("@radix-ui/react-slot");const s=m.default.forwardRef(({...e},t)=>{const{asChild:o,children:n,className:p,overflow:y,...x}=e,i=o?c.Slot:"div";return(0,m.useMemo)(()=>y==="hidden"?(0,r.jsx)("div",{className:(0,l.cn)("overflow-hidden","tablet:my-[80px] laptop:my-[96px] desktop:my-[112px] lg-desktop:my-[128px] my-[64px]",p),children:(0,r.jsx)(i,{className:(0,l.cn)("mx-auto box-border w-full max-w-[1772px]","tablet:px-8 laptop:px-16 desktop:px-16 lg-desktop:px-32 px-8"),...x,ref:t,children:n})}):(0,r.jsx)(i,{...x,ref:t,className:(0,l.cn)("mx-auto box-content w-full max-w-[1664px]","tablet:px-8 laptop:px-16 desktop:px-16 lg-desktop:px-32 px-8","tablet:my-[80px] laptop:my-[96px] desktop:my-[112px] lg-desktop:my-[128px] my-[64px]",p),children:n}),[e])});s.displayName="Container";
2
2
  //# sourceMappingURL=container.js.map
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../../src/components/container.tsx"],
4
- "sourcesContent": ["'use client'\nimport React, { useMemo } from 'react'\nimport { cn } from '../helpers/utils.js'\nimport { Slot } from '@radix-ui/react-slot'\n\ntype ContainerElement = React.ElementRef<'div'>\ntype ContainerProps = {\n asChild?: boolean\n children?: React.ReactNode\n className?: string\n overflow?: 'hidden'\n} & React.ComponentPropsWithoutRef<'div'>\nconst Container = React.forwardRef<ContainerElement, ContainerProps>(({ ...props }, forwardedRef) => {\n const { asChild, children, className, overflow, ...containerProps } = props\n const Comp = asChild ? Slot : 'div'\n\n const content = useMemo(() => {\n if (overflow === 'hidden') {\n return (\n <div\n className={cn(\n 'overflow-hidden',\n 'tablet:my-[80px] laptop:my-[96px] desktop:my-[112px] lg-desktop:my-[128px] my-[64px]',\n className\n )}\n >\n <Comp\n className={cn(\n 'mx-auto box-content w-full max-w-[1664px]',\n 'tablet:px-8 laptop:px-16 desktop:px-16 lg-desktop:px-32 px-8'\n )}\n {...containerProps}\n ref={forwardedRef}\n >\n {children}\n </Comp>\n </div>\n )\n }\n return (\n <Comp\n {...containerProps}\n ref={forwardedRef}\n className={cn(\n 'mx-auto box-content w-full max-w-[1664px]',\n 'tablet:px-8 laptop:px-16 desktop:px-16 lg-desktop:px-32 px-8',\n 'tablet:my-[80px] laptop:my-[96px] desktop:my-[112px] lg-desktop:my-[128px] my-[64px]',\n className\n )}\n >\n {children}\n </Comp>\n )\n }, [props])\n\n return content\n})\n\nContainer.displayName = 'Container'\n\nexport { Container }\nexport type { ContainerProps }\n"],
5
- "mappings": "ukBAAA,IAAAA,EAAA,GAAAC,EAAAD,EAAA,eAAAE,IAAA,eAAAC,EAAAH,GA0BU,IAAAI,EAAA,6BAzBVC,EAA+B,oBAC/BC,EAAmB,+BACnBC,EAAqB,gCASrB,MAAML,EAAY,EAAAM,QAAM,WAA6C,CAAC,CAAE,GAAGC,CAAM,EAAGC,IAAiB,CACnG,KAAM,CAAE,QAAAC,EAAS,SAAAC,EAAU,UAAAC,EAAW,SAAAC,EAAU,GAAGC,CAAe,EAAIN,EAChEO,EAAOL,EAAU,OAAO,MAyC9B,SAvCgB,WAAQ,IAClBG,IAAa,YAEb,OAAC,OACC,aAAW,MACT,kBACA,uFACAD,CACF,EAEA,mBAACG,EAAA,CACC,aAAW,MACT,4CACA,8DACF,EACC,GAAGD,EACJ,IAAKL,EAEJ,SAAAE,EACH,EACF,KAIF,OAACI,EAAA,CACE,GAAGD,EACJ,IAAKL,EACL,aAAW,MACT,4CACA,+DACA,uFACAG,CACF,EAEC,SAAAD,EACH,EAED,CAACH,CAAK,CAAC,CAGZ,CAAC,EAEDP,EAAU,YAAc",
4
+ "sourcesContent": ["'use client'\nimport React, { useMemo } from 'react'\nimport { cn } from '../helpers/utils.js'\nimport { Slot } from '@radix-ui/react-slot'\n\ntype ContainerElement = React.ElementRef<'div'>\ntype ContainerProps = {\n asChild?: boolean\n children?: React.ReactNode\n className?: string\n overflow?: 'hidden'\n} & React.ComponentPropsWithoutRef<'div'>\nconst Container = React.forwardRef<ContainerElement, ContainerProps>(({ ...props }, forwardedRef) => {\n const { asChild, children, className, overflow, ...containerProps } = props\n const Comp = asChild ? Slot : 'div'\n\n const content = useMemo(() => {\n if (overflow === 'hidden') {\n return (\n <div\n className={cn(\n 'overflow-hidden',\n 'tablet:my-[80px] laptop:my-[96px] desktop:my-[112px] lg-desktop:my-[128px] my-[64px]',\n className\n )}\n >\n <Comp\n className={cn(\n 'mx-auto box-border w-full max-w-[1772px]',\n 'tablet:px-8 laptop:px-16 desktop:px-16 lg-desktop:px-32 px-8'\n )}\n {...containerProps}\n ref={forwardedRef}\n >\n {children}\n </Comp>\n </div>\n )\n }\n return (\n <Comp\n {...containerProps}\n ref={forwardedRef}\n className={cn(\n 'mx-auto box-content w-full max-w-[1664px]',\n 'tablet:px-8 laptop:px-16 desktop:px-16 lg-desktop:px-32 px-8',\n 'tablet:my-[80px] laptop:my-[96px] desktop:my-[112px] lg-desktop:my-[128px] my-[64px]',\n className\n )}\n >\n {children}\n </Comp>\n )\n }, [props])\n\n return content\n})\n\nContainer.displayName = 'Container'\n\nexport { Container }\nexport type { ContainerProps }\n"],
5
+ "mappings": "ukBAAA,IAAAA,EAAA,GAAAC,EAAAD,EAAA,eAAAE,IAAA,eAAAC,EAAAH,GA0BU,IAAAI,EAAA,6BAzBVC,EAA+B,oBAC/BC,EAAmB,+BACnBC,EAAqB,gCASrB,MAAML,EAAY,EAAAM,QAAM,WAA6C,CAAC,CAAE,GAAGC,CAAM,EAAGC,IAAiB,CACnG,KAAM,CAAE,QAAAC,EAAS,SAAAC,EAAU,UAAAC,EAAW,SAAAC,EAAU,GAAGC,CAAe,EAAIN,EAChEO,EAAOL,EAAU,OAAO,MAyC9B,SAvCgB,WAAQ,IAClBG,IAAa,YAEb,OAAC,OACC,aAAW,MACT,kBACA,uFACAD,CACF,EAEA,mBAACG,EAAA,CACC,aAAW,MACT,2CACA,8DACF,EACC,GAAGD,EACJ,IAAKL,EAEJ,SAAAE,EACH,EACF,KAIF,OAACI,EAAA,CACE,GAAGD,EACJ,IAAKL,EACL,aAAW,MACT,4CACA,+DACA,uFACAG,CACF,EAEC,SAAAD,EACH,EAED,CAACH,CAAK,CAAC,CAGZ,CAAC,EAEDP,EAAU,YAAc",
6
6
  "names": ["container_exports", "__export", "Container", "__toCommonJS", "import_jsx_runtime", "import_react", "import_utils", "import_react_slot", "React", "props", "forwardedRef", "asChild", "children", "className", "overflow", "containerProps", "Comp"]
7
7
  }
@@ -1,2 +1,2 @@
1
- "use client";import{jsx as t}from"react/jsx-runtime";import i,{useMemo as d}from"react";import{cn as e}from"../helpers/utils.js";import{Slot as c}from"@radix-ui/react-slot";const r=i.forwardRef(({...o},p)=>{const{asChild:s,children:n,className:a,overflow:x,...l}=o,m=s?c:"div";return d(()=>x==="hidden"?t("div",{className:e("overflow-hidden","tablet:my-[80px] laptop:my-[96px] desktop:my-[112px] lg-desktop:my-[128px] my-[64px]",a),children:t(m,{className:e("mx-auto box-content w-full max-w-[1664px]","tablet:px-8 laptop:px-16 desktop:px-16 lg-desktop:px-32 px-8"),...l,ref:p,children:n})}):t(m,{...l,ref:p,className:e("mx-auto box-content w-full max-w-[1664px]","tablet:px-8 laptop:px-16 desktop:px-16 lg-desktop:px-32 px-8","tablet:my-[80px] laptop:my-[96px] desktop:my-[112px] lg-desktop:my-[128px] my-[64px]",a),children:n}),[o])});r.displayName="Container";export{r as Container};
1
+ "use client";import{jsx as t}from"react/jsx-runtime";import i,{useMemo as d}from"react";import{cn as e}from"../helpers/utils.js";import{Slot as c}from"@radix-ui/react-slot";const m=i.forwardRef(({...o},p)=>{const{asChild:s,children:n,className:a,overflow:x,...l}=o,r=s?c:"div";return d(()=>x==="hidden"?t("div",{className:e("overflow-hidden","tablet:my-[80px] laptop:my-[96px] desktop:my-[112px] lg-desktop:my-[128px] my-[64px]",a),children:t(r,{className:e("mx-auto box-border w-full max-w-[1772px]","tablet:px-8 laptop:px-16 desktop:px-16 lg-desktop:px-32 px-8"),...l,ref:p,children:n})}):t(r,{...l,ref:p,className:e("mx-auto box-content w-full max-w-[1664px]","tablet:px-8 laptop:px-16 desktop:px-16 lg-desktop:px-32 px-8","tablet:my-[80px] laptop:my-[96px] desktop:my-[112px] lg-desktop:my-[128px] my-[64px]",a),children:n}),[o])});m.displayName="Container";export{m as Container};
2
2
  //# sourceMappingURL=container.js.map
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../../src/components/container.tsx"],
4
- "sourcesContent": ["'use client'\nimport React, { useMemo } from 'react'\nimport { cn } from '../helpers/utils.js'\nimport { Slot } from '@radix-ui/react-slot'\n\ntype ContainerElement = React.ElementRef<'div'>\ntype ContainerProps = {\n asChild?: boolean\n children?: React.ReactNode\n className?: string\n overflow?: 'hidden'\n} & React.ComponentPropsWithoutRef<'div'>\nconst Container = React.forwardRef<ContainerElement, ContainerProps>(({ ...props }, forwardedRef) => {\n const { asChild, children, className, overflow, ...containerProps } = props\n const Comp = asChild ? Slot : 'div'\n\n const content = useMemo(() => {\n if (overflow === 'hidden') {\n return (\n <div\n className={cn(\n 'overflow-hidden',\n 'tablet:my-[80px] laptop:my-[96px] desktop:my-[112px] lg-desktop:my-[128px] my-[64px]',\n className\n )}\n >\n <Comp\n className={cn(\n 'mx-auto box-content w-full max-w-[1664px]',\n 'tablet:px-8 laptop:px-16 desktop:px-16 lg-desktop:px-32 px-8'\n )}\n {...containerProps}\n ref={forwardedRef}\n >\n {children}\n </Comp>\n </div>\n )\n }\n return (\n <Comp\n {...containerProps}\n ref={forwardedRef}\n className={cn(\n 'mx-auto box-content w-full max-w-[1664px]',\n 'tablet:px-8 laptop:px-16 desktop:px-16 lg-desktop:px-32 px-8',\n 'tablet:my-[80px] laptop:my-[96px] desktop:my-[112px] lg-desktop:my-[128px] my-[64px]',\n className\n )}\n >\n {children}\n </Comp>\n )\n }, [props])\n\n return content\n})\n\nContainer.displayName = 'Container'\n\nexport { Container }\nexport type { ContainerProps }\n"],
5
- "mappings": "aA0BU,cAAAA,MAAA,oBAzBV,OAAOC,GAAS,WAAAC,MAAe,QAC/B,OAAS,MAAAC,MAAU,sBACnB,OAAS,QAAAC,MAAY,uBASrB,MAAMC,EAAYJ,EAAM,WAA6C,CAAC,CAAE,GAAGK,CAAM,EAAGC,IAAiB,CACnG,KAAM,CAAE,QAAAC,EAAS,SAAAC,EAAU,UAAAC,EAAW,SAAAC,EAAU,GAAGC,CAAe,EAAIN,EAChEO,EAAOL,EAAUJ,EAAO,MAyC9B,OAvCgBF,EAAQ,IAClBS,IAAa,SAEbX,EAAC,OACC,UAAWG,EACT,kBACA,uFACAO,CACF,EAEA,SAAAV,EAACa,EAAA,CACC,UAAWV,EACT,4CACA,8DACF,EACC,GAAGS,EACJ,IAAKL,EAEJ,SAAAE,EACH,EACF,EAIFT,EAACa,EAAA,CACE,GAAGD,EACJ,IAAKL,EACL,UAAWJ,EACT,4CACA,+DACA,uFACAO,CACF,EAEC,SAAAD,EACH,EAED,CAACH,CAAK,CAAC,CAGZ,CAAC,EAEDD,EAAU,YAAc",
4
+ "sourcesContent": ["'use client'\nimport React, { useMemo } from 'react'\nimport { cn } from '../helpers/utils.js'\nimport { Slot } from '@radix-ui/react-slot'\n\ntype ContainerElement = React.ElementRef<'div'>\ntype ContainerProps = {\n asChild?: boolean\n children?: React.ReactNode\n className?: string\n overflow?: 'hidden'\n} & React.ComponentPropsWithoutRef<'div'>\nconst Container = React.forwardRef<ContainerElement, ContainerProps>(({ ...props }, forwardedRef) => {\n const { asChild, children, className, overflow, ...containerProps } = props\n const Comp = asChild ? Slot : 'div'\n\n const content = useMemo(() => {\n if (overflow === 'hidden') {\n return (\n <div\n className={cn(\n 'overflow-hidden',\n 'tablet:my-[80px] laptop:my-[96px] desktop:my-[112px] lg-desktop:my-[128px] my-[64px]',\n className\n )}\n >\n <Comp\n className={cn(\n 'mx-auto box-border w-full max-w-[1772px]',\n 'tablet:px-8 laptop:px-16 desktop:px-16 lg-desktop:px-32 px-8'\n )}\n {...containerProps}\n ref={forwardedRef}\n >\n {children}\n </Comp>\n </div>\n )\n }\n return (\n <Comp\n {...containerProps}\n ref={forwardedRef}\n className={cn(\n 'mx-auto box-content w-full max-w-[1664px]',\n 'tablet:px-8 laptop:px-16 desktop:px-16 lg-desktop:px-32 px-8',\n 'tablet:my-[80px] laptop:my-[96px] desktop:my-[112px] lg-desktop:my-[128px] my-[64px]',\n className\n )}\n >\n {children}\n </Comp>\n )\n }, [props])\n\n return content\n})\n\nContainer.displayName = 'Container'\n\nexport { Container }\nexport type { ContainerProps }\n"],
5
+ "mappings": "aA0BU,cAAAA,MAAA,oBAzBV,OAAOC,GAAS,WAAAC,MAAe,QAC/B,OAAS,MAAAC,MAAU,sBACnB,OAAS,QAAAC,MAAY,uBASrB,MAAMC,EAAYJ,EAAM,WAA6C,CAAC,CAAE,GAAGK,CAAM,EAAGC,IAAiB,CACnG,KAAM,CAAE,QAAAC,EAAS,SAAAC,EAAU,UAAAC,EAAW,SAAAC,EAAU,GAAGC,CAAe,EAAIN,EAChEO,EAAOL,EAAUJ,EAAO,MAyC9B,OAvCgBF,EAAQ,IAClBS,IAAa,SAEbX,EAAC,OACC,UAAWG,EACT,kBACA,uFACAO,CACF,EAEA,SAAAV,EAACa,EAAA,CACC,UAAWV,EACT,2CACA,8DACF,EACC,GAAGS,EACJ,IAAKL,EAEJ,SAAAE,EACH,EACF,EAIFT,EAACa,EAAA,CACE,GAAGD,EACJ,IAAKL,EACL,UAAWJ,EACT,4CACA,+DACA,uFACAO,CACF,EAEC,SAAAD,EACH,EAED,CAACH,CAAK,CAAC,CAGZ,CAAC,EAEDD,EAAU,YAAc",
6
6
  "names": ["jsx", "React", "useMemo", "cn", "Slot", "Container", "props", "forwardedRef", "asChild", "children", "className", "overflow", "containerProps", "Comp"]
7
7
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@anker-in/headless-ui",
3
- "version": "0.0.27-alpha.34",
3
+ "version": "0.0.27-alpha.36",
4
4
  "type": "commonjs",
5
5
  "main": "./dist/cjs/index.js",
6
6
  "types": "./dist/cjs/index.d.ts",
package/style.css CHANGED
@@ -669,6 +669,9 @@ video {
669
669
  .mt-auto {
670
670
  margin-top: auto;
671
671
  }
672
+ .box-border {
673
+ box-sizing: border-box;
674
+ }
672
675
  .box-content {
673
676
  box-sizing: content-box;
674
677
  }
@@ -795,6 +798,9 @@ video {
795
798
  .max-w-\[1664px\] {
796
799
  max-width: 1664px;
797
800
  }
801
+ .max-w-\[1772px\] {
802
+ max-width: 1772px;
803
+ }
798
804
  .max-w-lg {
799
805
  max-width: 32rem;
800
806
  }