@kushagradhawan/kookie-ui 0.1.7 → 0.1.9
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/components.css +99 -0
- package/dist/cjs/components/image.d.ts +21 -0
- package/dist/cjs/components/image.d.ts.map +1 -0
- package/dist/cjs/components/image.js +2 -0
- package/dist/cjs/components/image.js.map +7 -0
- package/dist/cjs/components/image.props.d.ts +49 -0
- package/dist/cjs/components/image.props.d.ts.map +1 -0
- package/dist/cjs/components/image.props.js +2 -0
- package/dist/cjs/components/image.props.js.map +7 -0
- package/dist/cjs/components/index.d.ts +1 -0
- package/dist/cjs/components/index.d.ts.map +1 -1
- package/dist/cjs/components/index.js +1 -1
- package/dist/cjs/components/index.js.map +3 -3
- package/dist/cjs/props/index.d.ts +2 -0
- package/dist/cjs/props/index.d.ts.map +1 -1
- package/dist/cjs/props/index.js +1 -1
- package/dist/cjs/props/index.js.map +2 -2
- package/dist/cjs/props/shadow.props.d.ts +24 -0
- package/dist/cjs/props/shadow.props.d.ts.map +1 -0
- package/dist/cjs/props/shadow.props.js +2 -0
- package/dist/cjs/props/shadow.props.js.map +7 -0
- package/dist/esm/components/image.d.ts +21 -0
- package/dist/esm/components/image.d.ts.map +1 -0
- package/dist/esm/components/image.js +2 -0
- package/dist/esm/components/image.js.map +7 -0
- package/dist/esm/components/image.props.d.ts +49 -0
- package/dist/esm/components/image.props.d.ts.map +1 -0
- package/dist/esm/components/image.props.js +2 -0
- package/dist/esm/components/image.props.js.map +7 -0
- package/dist/esm/components/index.d.ts +1 -0
- package/dist/esm/components/index.d.ts.map +1 -1
- package/dist/esm/components/index.js +1 -1
- package/dist/esm/components/index.js.map +3 -3
- package/dist/esm/props/index.d.ts +2 -0
- package/dist/esm/props/index.d.ts.map +1 -1
- package/dist/esm/props/index.js +1 -1
- package/dist/esm/props/index.js.map +2 -2
- package/dist/esm/props/shadow.props.d.ts +24 -0
- package/dist/esm/props/shadow.props.d.ts.map +1 -0
- package/dist/esm/props/shadow.props.js +2 -0
- package/dist/esm/props/shadow.props.js.map +7 -0
- package/package.json +1 -1
- package/src/components/image.css +140 -0
- package/src/components/image.props.ts +50 -0
- package/src/components/image.tsx +191 -0
- package/src/components/index.css +1 -0
- package/src/components/index.tsx +1 -0
- package/src/components/text.css +1 -0
- package/src/props/index.ts +2 -0
- package/src/props/shadow.props.ts +30 -0
- package/styles.css +99 -0
package/components.css
CHANGED
|
@@ -580,6 +580,7 @@
|
|
|
580
580
|
}
|
|
581
581
|
}
|
|
582
582
|
.rt-Text {
|
|
583
|
+
font-family: var(--default-font-family);
|
|
583
584
|
line-height: var(--line-height, var(--default-line-height));
|
|
584
585
|
letter-spacing: var(--letter-spacing, inherit);
|
|
585
586
|
}
|
|
@@ -5970,6 +5971,104 @@
|
|
|
5970
5971
|
--icon-button-ghost-padding: var(--space-3);
|
|
5971
5972
|
}
|
|
5972
5973
|
}
|
|
5974
|
+
.rt-Image {
|
|
5975
|
+
display: block;
|
|
5976
|
+
object-fit: var(--object-fit);
|
|
5977
|
+
box-shadow: var(--box-shadow);
|
|
5978
|
+
border-radius: max(var(--radius-4), var(--radius-full));
|
|
5979
|
+
transition: var(--transition-button);
|
|
5980
|
+
}
|
|
5981
|
+
.rt-Image:where(:any-link, button, label) {
|
|
5982
|
+
cursor: pointer;
|
|
5983
|
+
}
|
|
5984
|
+
@media (hover: hover) {
|
|
5985
|
+
.rt-Image:where(:any-link, button, label):where(:hover) {
|
|
5986
|
+
transform: scale(1.02);
|
|
5987
|
+
box-shadow: var(--box-shadow, var(--shadow-2)), 0 0 0 1px var(--gray-a4);
|
|
5988
|
+
}
|
|
5989
|
+
}
|
|
5990
|
+
.rt-Image:where(:any-link, button, label):where(:focus-visible) {
|
|
5991
|
+
outline: 2px solid var(--focus-8);
|
|
5992
|
+
outline-offset: 2px;
|
|
5993
|
+
}
|
|
5994
|
+
.rt-Image:where(:any-link, button, label):where(:active) {
|
|
5995
|
+
transform: scale(0.98);
|
|
5996
|
+
}
|
|
5997
|
+
.rt-variant-blur {
|
|
5998
|
+
position: relative;
|
|
5999
|
+
display: inline-block;
|
|
6000
|
+
--blur-filter: blur(16px) saturate(1.5);
|
|
6001
|
+
--blur-opacity: 0.5;
|
|
6002
|
+
--blur-offset-y: 8px;
|
|
6003
|
+
--blur-offset-x: 0;
|
|
6004
|
+
}
|
|
6005
|
+
.rt-variant-blur:where(:any-link, button, label) {
|
|
6006
|
+
cursor: pointer;
|
|
6007
|
+
transition: var(--transition-button);
|
|
6008
|
+
}
|
|
6009
|
+
@media (hover: hover) {
|
|
6010
|
+
.rt-variant-blur:where(:any-link, button, label):where(:hover) {
|
|
6011
|
+
transform: scale(1.02);
|
|
6012
|
+
}
|
|
6013
|
+
}
|
|
6014
|
+
.rt-variant-blur:where(:any-link, button, label):where(:focus-visible) {
|
|
6015
|
+
outline: 2px solid var(--focus-8);
|
|
6016
|
+
outline-offset: 2px;
|
|
6017
|
+
}
|
|
6018
|
+
.rt-variant-blur:where(:any-link, button, label):where(:active) {
|
|
6019
|
+
transform: scale(0.98);
|
|
6020
|
+
}
|
|
6021
|
+
.rt-variant-blur:where(:any-link, button, label) .rt-Image {
|
|
6022
|
+
cursor: inherit;
|
|
6023
|
+
transform: none !important;
|
|
6024
|
+
outline: none !important;
|
|
6025
|
+
box-shadow: var(--box-shadow) !important;
|
|
6026
|
+
}
|
|
6027
|
+
.rt-Image--blur-bg {
|
|
6028
|
+
position: absolute;
|
|
6029
|
+
top: var(--blur-offset-y, 8px);
|
|
6030
|
+
left: var(--blur-offset-x, 0);
|
|
6031
|
+
filter: var(--blur-filter);
|
|
6032
|
+
opacity: var(--blur-opacity);
|
|
6033
|
+
z-index: -1;
|
|
6034
|
+
}
|
|
6035
|
+
.rt-Image--blur {
|
|
6036
|
+
position: relative;
|
|
6037
|
+
z-index: 1;
|
|
6038
|
+
}
|
|
6039
|
+
.rt-r-fit-cover {
|
|
6040
|
+
--object-fit: cover;
|
|
6041
|
+
}
|
|
6042
|
+
.rt-r-fit-contain {
|
|
6043
|
+
--object-fit: contain;
|
|
6044
|
+
}
|
|
6045
|
+
.rt-r-fit-fill {
|
|
6046
|
+
--object-fit: fill;
|
|
6047
|
+
}
|
|
6048
|
+
.rt-r-fit-scale-down {
|
|
6049
|
+
--object-fit: scale-down;
|
|
6050
|
+
}
|
|
6051
|
+
.rt-r-fit-none {
|
|
6052
|
+
--object-fit: none;
|
|
6053
|
+
}
|
|
6054
|
+
.rt-r-shadow-1 {
|
|
6055
|
+
--box-shadow: var(--shadow-1);
|
|
6056
|
+
}
|
|
6057
|
+
.rt-r-shadow-2 {
|
|
6058
|
+
--box-shadow: var(--shadow-2);
|
|
6059
|
+
}
|
|
6060
|
+
.rt-r-shadow-3 {
|
|
6061
|
+
--box-shadow: var(--shadow-3);
|
|
6062
|
+
}
|
|
6063
|
+
.rt-r-shadow-4 {
|
|
6064
|
+
--box-shadow: var(--shadow-4);
|
|
6065
|
+
}
|
|
6066
|
+
.rt-r-shadow-5 {
|
|
6067
|
+
--box-shadow: var(--shadow-5);
|
|
6068
|
+
}
|
|
6069
|
+
.rt-r-shadow-6 {
|
|
6070
|
+
--box-shadow: var(--shadow-6);
|
|
6071
|
+
}
|
|
5973
6072
|
.rt-Inset {
|
|
5974
6073
|
box-sizing: border-box;
|
|
5975
6074
|
--margin-top: 0px;
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
import { imagePropDefs } from './image.props.js';
|
|
3
|
+
import type { ComponentPropsWithout, RemovedProps } from '../helpers/component-props.js';
|
|
4
|
+
import type { MarginProps } from '../props/margin.props.js';
|
|
5
|
+
import type { WidthProps } from '../props/width.props.js';
|
|
6
|
+
import type { HeightProps } from '../props/height.props.js';
|
|
7
|
+
import type { GetPropDefTypes } from '../props/prop-def.js';
|
|
8
|
+
type ImageOwnProps = GetPropDefTypes<typeof imagePropDefs> & {
|
|
9
|
+
loading?: 'eager' | 'lazy';
|
|
10
|
+
};
|
|
11
|
+
interface ImageProps extends ComponentPropsWithout<'img', RemovedProps | 'color' | 'width' | 'height' | 'alt'>, MarginProps, WidthProps, HeightProps, ImageOwnProps {
|
|
12
|
+
/**
|
|
13
|
+
* The alt attribute provides alternative information for an image if a user for some reason cannot view it.
|
|
14
|
+
* Required for accessibility when not using asChild.
|
|
15
|
+
*/
|
|
16
|
+
alt?: string;
|
|
17
|
+
}
|
|
18
|
+
declare const Image: React.ForwardRefExoticComponent<ImageProps & React.RefAttributes<HTMLImageElement>>;
|
|
19
|
+
export { Image };
|
|
20
|
+
export type { ImageProps };
|
|
21
|
+
//# sourceMappingURL=image.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"image.d.ts","sourceRoot":"","sources":["../../../src/components/image.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAG/B,OAAO,EAAE,aAAa,EAAE,MAAM,kBAAkB,CAAC;AAMjD,OAAO,KAAK,EAAE,qBAAqB,EAAE,YAAY,EAAE,MAAM,+BAA+B,CAAC;AACzF,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,0BAA0B,CAAC;AAC5D,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,yBAAyB,CAAC;AAC1D,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,0BAA0B,CAAC;AAC5D,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,sBAAsB,CAAC;AAG5D,KAAK,aAAa,GAAG,eAAe,CAAC,OAAO,aAAa,CAAC,GAAG;IAC3D,OAAO,CAAC,EAAE,OAAO,GAAG,MAAM,CAAC;CAC5B,CAAC;AAEF,UAAU,UACR,SAAQ,qBAAqB,CAAC,KAAK,EAAE,YAAY,GAAG,OAAO,GAAG,OAAO,GAAG,QAAQ,GAAG,KAAK,CAAC,EACvF,WAAW,EACX,UAAU,EACV,WAAW,EACX,aAAa;IACf;;;OAGG;IACH,GAAG,CAAC,EAAE,MAAM,CAAC;CACd;AAED,QAAA,MAAM,KAAK,qFAsJT,CAAC;AAIH,OAAO,EAAE,KAAK,EAAE,CAAC;AACjB,YAAY,EAAE,UAAU,EAAE,CAAC"}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
"use strict";"use client";var j=Object.create;var c=Object.defineProperty;var k=Object.getOwnPropertyDescriptor;var w=Object.getOwnPropertyNames;var z=Object.getPrototypeOf,C=Object.prototype.hasOwnProperty;var W=(e,r)=>{for(var t in r)c(e,t,{get:r[t],enumerable:!0})},I=(e,r,t,f)=>{if(r&&typeof r=="object"||typeof r=="function")for(let s of w(r))!C.call(e,s)&&s!==t&&c(e,s,{get:()=>r[s],enumerable:!(f=k(r,s))||f.enumerable});return e};var P=(e,r,t)=>(t=e!=null?j(z(e)):{},I(r||!e||!e.__esModule?c(t,"default",{value:e,enumerable:!0}):t,e)),G=e=>I(c({},"__esModule",{value:!0}),e);var H={};W(H,{Image:()=>y});module.exports=G(H);var o=P(require("react")),a=P(require("classnames")),b=require("./image.props.js"),N=require("../helpers/extract-props.js"),v=require("../props/margin.props.js"),x=require("../props/width.props.js"),D=require("../props/height.props.js");const y=o.forwardRef((e,r)=>{const{variant:t="surface",fit:f="cover",children:s}=e,{asChild:E,className:p,radius:l,style:n,loading:m="lazy",alt:u,src:g,children:M,...d}=(0,N.extractProps)(e,b.imagePropDefs,v.marginPropDefs,x.widthPropDefs,D.heightPropDefs),h=o.createElement("img",{"data-radius":l,loading:m,style:n,className:(0,a.default)("rt-reset","rt-Image",t==="blur"&&"rt-Image--blur",p),alt:u,src:g,...d,ref:r});if(E&&s){const i=o.Children.only(s);return t==="blur"?o.cloneElement(i,{className:(0,a.default)(i.props?.className,"rt-variant-blur"),style:{position:"relative",display:"inline-block",textDecoration:"none",color:"inherit",border:"none",background:"none",padding:0,font:"inherit",cursor:"pointer",...i.props?.style},children:o.createElement(o.Fragment,null,o.createElement("img",{"data-radius":l,loading:m,style:{...n,position:"absolute",top:"8px",left:"0"},className:(0,a.default)("rt-reset","rt-Image","rt-Image--blur","rt-Image--blur-bg",p),alt:"",src:g,...d}),o.createElement("img",{"data-radius":l,loading:m,style:{...n,position:"relative",zIndex:1},className:(0,a.default)("rt-reset","rt-Image","rt-Image--blur",p),alt:u,src:g,...d,ref:r}))}):o.cloneElement(i,{className:(0,a.default)(i.props?.className,"rt-Image"),style:{textDecoration:"none",color:"inherit",border:"none",background:"none",padding:0,font:"inherit",cursor:"pointer",...i.props?.style},children:h})}return t==="blur"?o.createElement("div",{className:"rt-variant-blur",style:{position:"relative",display:"inline-block"}},o.createElement("img",{"data-radius":l,loading:m,style:{...n,position:"absolute",top:"8px",left:"0"},className:(0,a.default)("rt-reset","rt-Image","rt-Image--blur","rt-Image--blur-bg",p),alt:"",src:g,...d}),o.createElement("img",{"data-radius":l,loading:m,style:{...n,position:"relative",zIndex:1},className:(0,a.default)("rt-reset","rt-Image","rt-Image--blur",p),alt:u,src:g,...d,ref:r})):h});y.displayName="Image";
|
|
2
|
+
//# sourceMappingURL=image.js.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../src/components/image.tsx"],
|
|
4
|
+
"sourcesContent": ["'use client';\n\nimport * as React from 'react';\nimport classNames from 'classnames';\n\nimport { imagePropDefs } from './image.props.js';\nimport { extractProps } from '../helpers/extract-props.js';\nimport { marginPropDefs } from '../props/margin.props.js';\nimport { widthPropDefs } from '../props/width.props.js';\nimport { heightPropDefs } from '../props/height.props.js';\n\nimport type { ComponentPropsWithout, RemovedProps } from '../helpers/component-props.js';\nimport type { MarginProps } from '../props/margin.props.js';\nimport type { WidthProps } from '../props/width.props.js';\nimport type { HeightProps } from '../props/height.props.js';\nimport type { GetPropDefTypes } from '../props/prop-def.js';\n\ntype ImageElement = React.ElementRef<'img'>;\ntype ImageOwnProps = GetPropDefTypes<typeof imagePropDefs> & {\n loading?: 'eager' | 'lazy';\n};\n\ninterface ImageProps\n extends ComponentPropsWithout<'img', RemovedProps | 'color' | 'width' | 'height' | 'alt'>,\n MarginProps,\n WidthProps,\n HeightProps,\n ImageOwnProps {\n /**\n * The alt attribute provides alternative information for an image if a user for some reason cannot view it.\n * Required for accessibility when not using asChild.\n */\n alt?: string;\n}\n\nconst Image = React.forwardRef<ImageElement, ImageProps>((props, forwardedRef) => {\n const { variant = 'surface', fit = 'cover', children } = props;\n const {\n asChild,\n className,\n radius,\n style,\n loading = 'lazy',\n alt,\n src,\n children: _children, // Extract children to exclude from imgProps\n ...imgProps\n } = extractProps(props, imagePropDefs, marginPropDefs, widthPropDefs, heightPropDefs);\n\n // Create the standard img element\n const imgElement = (\n <img\n data-radius={radius}\n loading={loading}\n style={style}\n className={classNames(\n 'rt-reset',\n 'rt-Image',\n variant === 'blur' && 'rt-Image--blur',\n className,\n )}\n alt={alt}\n src={src}\n {...imgProps}\n ref={forwardedRef}\n />\n );\n\n // Handle asChild - inject img into the child element\n if (asChild && children) {\n const child = React.Children.only(children) as React.ReactElement<any>;\n\n if (variant === 'blur') {\n // For blur variant with asChild\n return React.cloneElement(child, {\n className: classNames(child.props?.className, 'rt-variant-blur'),\n style: {\n position: 'relative',\n display: 'inline-block',\n textDecoration: 'none', // Reset link underlines\n color: 'inherit', // Reset link colors\n border: 'none', // Reset button borders\n background: 'none', // Reset button backgrounds\n padding: 0, // Reset button padding\n font: 'inherit', // Reset button fonts\n cursor: 'pointer', // Ensure interactive cursor\n ...child.props?.style,\n },\n children: (\n <>\n {/* Background blurred image */}\n <img\n data-radius={radius}\n loading={loading}\n style={{\n ...style,\n position: 'absolute',\n top: '8px',\n left: '0',\n }}\n className={classNames(\n 'rt-reset',\n 'rt-Image',\n 'rt-Image--blur',\n 'rt-Image--blur-bg',\n className,\n )}\n alt=\"\"\n src={src}\n {...imgProps}\n />\n {/* Foreground image */}\n <img\n data-radius={radius}\n loading={loading}\n style={{ ...style, position: 'relative', zIndex: 1 }}\n className={classNames('rt-reset', 'rt-Image', 'rt-Image--blur', className)}\n alt={alt}\n src={src}\n {...imgProps}\n ref={forwardedRef}\n />\n </>\n ),\n });\n } else {\n // For surface variant with asChild\n return React.cloneElement(child, {\n className: classNames(child.props?.className, 'rt-Image'),\n style: {\n textDecoration: 'none', // Reset link underlines\n color: 'inherit', // Reset link colors\n border: 'none', // Reset button borders\n background: 'none', // Reset button backgrounds\n padding: 0, // Reset button padding\n font: 'inherit', // Reset button fonts\n cursor: 'pointer', // Ensure interactive cursor\n ...child.props?.style, // Allow user overrides\n },\n children: imgElement,\n });\n }\n }\n\n // Regular rendering without asChild\n if (variant === 'blur') {\n return (\n <div className=\"rt-variant-blur\" style={{ position: 'relative', display: 'inline-block' }}>\n {/* Background blurred image */}\n <img\n data-radius={radius}\n loading={loading}\n style={{\n ...style,\n position: 'absolute',\n top: '8px',\n left: '0',\n }}\n className={classNames(\n 'rt-reset',\n 'rt-Image',\n 'rt-Image--blur',\n 'rt-Image--blur-bg',\n className,\n )}\n alt=\"\"\n src={src}\n {...imgProps}\n />\n {/* Foreground image */}\n <img\n data-radius={radius}\n loading={loading}\n style={{ ...style, position: 'relative', zIndex: 1 }}\n className={classNames('rt-reset', 'rt-Image', 'rt-Image--blur', className)}\n alt={alt}\n src={src}\n {...imgProps}\n ref={forwardedRef}\n />\n </div>\n );\n }\n\n return imgElement;\n});\n\nImage.displayName = 'Image';\n\nexport { Image };\nexport type { ImageProps };\n"],
|
|
5
|
+
"mappings": "ukBAAA,IAAAA,EAAA,GAAAC,EAAAD,EAAA,WAAAE,IAAA,eAAAC,EAAAH,GAEA,IAAAI,EAAuB,oBACvBC,EAAuB,yBAEvBC,EAA8B,4BAC9BC,EAA6B,uCAC7BC,EAA+B,oCAC/BC,EAA8B,mCAC9BC,EAA+B,oCA0B/B,MAAMR,EAAQE,EAAM,WAAqC,CAACO,EAAOC,IAAiB,CAChF,KAAM,CAAE,QAAAC,EAAU,UAAW,IAAAC,EAAM,QAAS,SAAAC,CAAS,EAAIJ,EACnD,CACJ,QAAAK,EAC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R,WAAY,OACZ,QAAS,EACT,KAAM,UACN,OAAQ,UACR,GAAGA,EAAM,OAAO,KAClB,EACA,SAAUF,CACZ,CAAC,CAEL,CAGA,OAAIZ,IAAY,OAEZT,EAAA,cAAC,OAAI,UAAU,kBAAkB,MAAO,CAAE,SAAU,WAAY,QAAS,cAAe,GAEtFA,EAAA,cAAC,OACC,cAAac,EACb,QAASE,EACT,MAAO,CACL,GAAGD,EACH,SAAU,WACV,IAAK,MACL,KAAM,GACR,EACA,aAAW,EAAAO,SACT,WACA,WACA,iBACA,oBACAT,CACF,EACA,IAAI,GACJ,IAAKK,EACJ,GAAGE,EACN,EAEApB,EAAA,cAAC,OACC,cAAac,EACb,QAASE,EACT,MAAO,CAAE,GAAGD,EAAO,SAAU,WAAY,OAAQ,CAAE,EACnD,aAAW,EAAAO,SAAW,WAAY,WAAY,iBAAkBT,CAAS,EACzE,IAAKI,EACL,IAAKC,EACJ,GAAGE,EACJ,IAAKZ,EACP,CACF,EAIGa,CACT,CAAC,EAEDvB,EAAM,YAAc",
|
|
6
|
+
"names": ["image_exports", "__export", "Image", "__toCommonJS", "React", "import_classnames", "import_image_props", "import_extract_props", "import_margin_props", "import_width_props", "import_height_props", "props", "forwardedRef", "variant", "fit", "children", "asChild", "className", "radius", "style", "loading", "alt", "src", "_children", "imgProps", "imgElement", "classNames", "child"]
|
|
7
|
+
}
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
declare const imagePropDefs: {
|
|
2
|
+
shadow: {
|
|
3
|
+
type: "enum";
|
|
4
|
+
className: string;
|
|
5
|
+
values: readonly ["1", "2", "3", "4", "5", "6"];
|
|
6
|
+
responsive: true;
|
|
7
|
+
};
|
|
8
|
+
radius: {
|
|
9
|
+
type: "enum";
|
|
10
|
+
values: readonly ["none", "small", "medium", "large", "full"];
|
|
11
|
+
default: undefined;
|
|
12
|
+
};
|
|
13
|
+
/**
|
|
14
|
+
* Sets the CSS **object-fit** property.
|
|
15
|
+
* Controls how the image should be resized to fit its container.
|
|
16
|
+
*
|
|
17
|
+
* @example
|
|
18
|
+
* fit="cover"
|
|
19
|
+
* fit="contain"
|
|
20
|
+
*
|
|
21
|
+
* @link
|
|
22
|
+
* https://developer.mozilla.org/en-US/docs/Web/CSS/object-fit
|
|
23
|
+
*/
|
|
24
|
+
fit: {
|
|
25
|
+
type: "enum";
|
|
26
|
+
className: string;
|
|
27
|
+
values: readonly ["cover", "contain", "fill", "scale-down", "none"];
|
|
28
|
+
default: "cover";
|
|
29
|
+
responsive: true;
|
|
30
|
+
};
|
|
31
|
+
/**
|
|
32
|
+
* Sets the visual variant of the image.
|
|
33
|
+
*
|
|
34
|
+
* @example
|
|
35
|
+
* variant="surface"
|
|
36
|
+
* variant="blur"
|
|
37
|
+
*/
|
|
38
|
+
variant: {
|
|
39
|
+
type: "enum";
|
|
40
|
+
className: string;
|
|
41
|
+
values: readonly ["surface", "blur"];
|
|
42
|
+
default: "surface";
|
|
43
|
+
};
|
|
44
|
+
asChild: {
|
|
45
|
+
type: "boolean";
|
|
46
|
+
};
|
|
47
|
+
};
|
|
48
|
+
export { imagePropDefs };
|
|
49
|
+
//# sourceMappingURL=image.props.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"image.props.d.ts","sourceRoot":"","sources":["../../../src/components/image.props.ts"],"names":[],"mappings":"AASA,QAAA,MAAM,aAAa;;;;;;;;;;;;IAEjB;;;;;;;;;;OAUG;;;;;;;;IAQH;;;;;;OAMG;;;;;;;;;;CAYJ,CAAC;AAEF,OAAO,EAAE,aAAa,EAAE,CAAC"}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
"use strict";var s=Object.defineProperty;var c=Object.getOwnPropertyDescriptor;var m=Object.getOwnPropertyNames;var u=Object.prototype.hasOwnProperty;var l=(r,e)=>{for(var t in e)s(r,t,{get:e[t],enumerable:!0})},v=(r,e,t,a)=>{if(e&&typeof e=="object"||typeof e=="function")for(let o of m(e))!u.call(r,o)&&o!==t&&s(r,o,{get:()=>e[o],enumerable:!(a=c(e,o))||a.enumerable});return r};var d=r=>v(s({},"__esModule",{value:!0}),r);var b={};l(b,{imagePropDefs:()=>n});module.exports=d(b);var f=require("../props/as-child.prop.js"),i=require("../props/radius.prop.js"),p=require("../props/shadow.props.js");const D=["cover","contain","fill","scale-down","none"],P=["surface","blur"],n={...f.asChildPropDef,fit:{type:"enum",className:"rt-r-fit",values:D,default:"cover",responsive:!0},variant:{type:"enum",className:"rt-variant",values:P,default:"surface"},...i.radiusPropDef,...p.shadowPropDefs};
|
|
2
|
+
//# sourceMappingURL=image.props.js.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../src/components/image.props.ts"],
|
|
4
|
+
"sourcesContent": ["import { asChildPropDef } from '../props/as-child.prop.js';\nimport { radiusPropDef } from '../props/radius.prop.js';\nimport { shadowPropDefs } from '../props/shadow.props.js';\n\nimport type { PropDef } from '../props/prop-def.js';\n\nconst objectFitValues = ['cover', 'contain', 'fill', 'scale-down', 'none'] as const;\nconst variants = ['surface', 'blur'] as const;\n\nconst imagePropDefs = {\n ...asChildPropDef,\n /**\n * Sets the CSS **object-fit** property.\n * Controls how the image should be resized to fit its container.\n *\n * @example\n * fit=\"cover\"\n * fit=\"contain\"\n *\n * @link\n * https://developer.mozilla.org/en-US/docs/Web/CSS/object-fit\n */\n fit: {\n type: 'enum',\n className: 'rt-r-fit',\n values: objectFitValues,\n default: 'cover',\n responsive: true,\n },\n /**\n * Sets the visual variant of the image.\n *\n * @example\n * variant=\"surface\"\n * variant=\"blur\"\n */\n variant: {\n type: 'enum',\n className: 'rt-variant',\n values: variants,\n default: 'surface',\n },\n ...radiusPropDef,\n ...shadowPropDefs,\n} satisfies {\n fit: PropDef<(typeof objectFitValues)[number]>;\n variant: PropDef<(typeof variants)[number]>;\n};\n\nexport { imagePropDefs };\n"],
|
|
5
|
+
"mappings": "yaAAA,IAAAA,EAAA,GAAAC,EAAAD,EAAA,mBAAAE,IAAA,eAAAC,EAAAH,GAAA,IAAAI,EAA+B,qCAC/BC,EAA8B,mCAC9BC,EAA+B,oCAI/B,MAAMC,EAAkB,CAAC,QAAS,UAAW,OAAQ,aAAc,MAAM,EACnEC,EAAW,CAAC,UAAW,MAAM,EAE7BN,EAAgB,CACpB,GAAG,iBAYH,IAAK,CACH,KAAM,OACN,UAAW,WACX,OAAQK,EACR,QAAS,QACT,WAAY,EACd,EAQA,QAAS,CACP,KAAM,OACN,UAAW,aACX,OAAQC,EACR,QAAS,SACX,EACA,GAAG,gBACH,GAAG,gBACL",
|
|
6
|
+
"names": ["image_props_exports", "__export", "imagePropDefs", "__toCommonJS", "import_as_child_prop", "import_radius_prop", "import_shadow_props", "objectFitValues", "variants"]
|
|
7
|
+
}
|
|
@@ -24,6 +24,7 @@ export { Heading, type HeadingProps } from './heading.js';
|
|
|
24
24
|
export * as HoverCard from './hover-card.js';
|
|
25
25
|
export { IconButton, type IconButtonProps } from './icon-button.js';
|
|
26
26
|
export { type IconProps, ChevronDownIcon, ThickCheckIcon, ThickChevronRightIcon, ThickDividerHorizontalIcon, } from './icons.js';
|
|
27
|
+
export { Image, type ImageProps } from './image.js';
|
|
27
28
|
export { Inset, type InsetProps } from './inset.js';
|
|
28
29
|
export { Kbd, type KbdProps } from './kbd.js';
|
|
29
30
|
export { Link, type LinkProps } from './link.js';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/index.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,KAAK,mBAAmB,EAAE,MAAM,sBAAsB,CAAC;AAChF,OAAO,KAAK,WAAW,MAAM,mBAAmB,CAAC;AACjD,OAAO,EAAE,WAAW,EAAE,KAAK,gBAAgB,EAAE,MAAM,mBAAmB,CAAC;AACvE,OAAO,EAAE,MAAM,EAAE,KAAK,WAAW,EAAE,MAAM,aAAa,CAAC;AACvD,OAAO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var $=Object.getOwnPropertyNames;var oo=Object.getPrototypeOf,ro=Object.prototype.hasOwnProperty;var eo=(r,e)=>{for(var t in e)m(r,t,{get:e[t],enumerable:!0})},n=(r,e,t,f)=>{if(e&&typeof e=="object"||typeof e=="function")for(let x of $(e))!ro.call(r,x)&&x!==t&&m(r,x,{get:()=>e[x],enumerable:!(f=_(e,x))||f.enumerable});return r};var o=(r,e,t)=>(t=r!=null?Z(oo(r)):{},n(e||!r||!r.__esModule?m(t,"default",{value:r,enumerable:!0}):t,r)),to=r=>n(m({},"__esModule",{value:!0}),r);var po={};eo(po,{AccessibleIcon:()=>P.AccessibleIcon,AlertDialog:()=>so,AspectRatio:()=>y.AspectRatio,Avatar:()=>i.Avatar,Badge:()=>l.Badge,Blockquote:()=>c.Blockquote,Box:()=>d.Box,Button:()=>T.Button,Callout:()=>xo,Card:()=>g.Card,Checkbox:()=>C.Checkbox,CheckboxCards:()=>mo,CheckboxGroup:()=>ao,ChevronDownIcon:()=>p.ChevronDownIcon,Code:()=>u.Code,Container:()=>S.Container,ContextMenu:()=>fo,DataList:()=>no,Dialog:()=>Po,DropdownMenu:()=>yo,Em:()=>h.Em,Flex:()=>I.Flex,Grid:()=>k.Grid,Heading:()=>B.Heading,HoverCard:()=>io,IconButton:()=>b.IconButton,Image:()=>A.Image,Inset:()=>R.Inset,Kbd:()=>v.Kbd,Link:()=>D.Link,Popover:()=>lo,Portal:()=>H.Portal,Progress:()=>w.Progress,Quote:()=>G.Quote,Radio:()=>F.Radio,RadioCards:()=>co,RadioGroup:()=>To,Reset:()=>L.Reset,ScrollArea:()=>q.ScrollArea,Section:()=>E.Section,SegmentedControl:()=>go,Select:()=>Co,Separator:()=>K.Separator,Skeleton:()=>M.Skeleton,Slider:()=>Q.Slider,Slot:()=>a.Slot,Slottable:()=>a.Slottable,Spinner:()=>V.Spinner,Strong:()=>z.Strong,Switch:()=>N.Switch,TabNav:()=>uo,Table:()=>So,Tabs:()=>ho,Text:()=>J.Text,TextArea:()=>j.TextArea,TextField:()=>Io,Theme:()=>s.Theme,ThemeContext:()=>s.ThemeContext,ThemePanel:()=>O.ThemePanel,ThickCheckIcon:()=>p.ThickCheckIcon,ThickChevronRightIcon:()=>p.ThickChevronRightIcon,ThickDividerHorizontalIcon:()=>p.ThickDividerHorizontalIcon,ToggleButton:()=>U.ToggleButton,ToggleIconButton:()=>W.ToggleIconButton,Tooltip:()=>X.Tooltip,VisuallyHidden:()=>Y.VisuallyHidden,useThemeContext:()=>s.useThemeContext});module.exports=to(po);var P=require("./accessible-icon.js"),so=o(require("./alert-dialog.js")),y=require("./aspect-ratio.js"),i=require("./avatar.js"),l=require("./badge.js"),c=require("./blockquote.js"),d=require("./box.js"),T=require("./button.js"),xo=o(require("./callout.js")),g=require("./card.js"),mo=o(require("./checkbox-cards.js")),ao=o(require("./checkbox-group.js")),C=require("./checkbox.js"),u=require("./code.js"),S=require("./container.js"),fo=o(require("./context-menu.js")),no=o(require("./data-list.js")),Po=o(require("./dialog.js")),yo=o(require("./dropdown-menu.js")),h=require("./em.js"),I=require("./flex.js"),k=require("./grid.js"),B=require("./heading.js"),io=o(require("./hover-card.js")),b=require("./icon-button.js"),p=require("./icons.js"),A=require("./image.js"),R=require("./inset.js"),v=require("./kbd.js"),D=require("./link.js"),lo=o(require("./popover.js")),H=require("./portal.js"),w=require("./progress.js"),G=require("./quote.js"),co=o(require("./radio-cards.js")),To=o(require("./radio-group.js")),F=require("./radio.js"),L=require("./reset.js"),q=require("./scroll-area.js"),go=o(require("./segmented-control.js")),E=require("./section.js"),Co=o(require("./select.js")),K=require("./separator.js"),M=require("./skeleton.js"),Q=require("./slider.js"),a=require("./slot.js"),V=require("./spinner.js"),z=require("./strong.js"),N=require("./switch.js"),uo=o(require("./tab-nav.js")),So=o(require("./table.js")),ho=o(require("./tabs.js")),j=require("./text-area.js"),Io=o(require("./text-field.js")),J=require("./text.js"),O=require("./theme-panel.js"),s=require("./theme.js"),U=require("./toggle-button.js"),W=require("./toggle-icon-button.js"),X=require("./tooltip.js"),Y=require("./visually-hidden.js");
|
|
2
2
|
//# sourceMappingURL=index.js.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../src/components/index.tsx"],
|
|
4
|
-
"sourcesContent": ["export { AccessibleIcon, type AccessibleIconProps } from './accessible-icon.js';\nexport * as AlertDialog from './alert-dialog.js';\nexport { AspectRatio, type AspectRatioProps } from './aspect-ratio.js';\nexport { Avatar, type AvatarProps } from './avatar.js';\nexport { Badge, type BadgeProps } from './badge.js';\nexport { Blockquote, type BlockquoteProps } from './blockquote.js';\nexport { Box, type BoxProps } from './box.js';\nexport { Button, type ButtonProps } from './button.js';\nexport * as Callout from './callout.js';\nexport { Card, type CardProps } from './card.js';\nexport * as CheckboxCards from './checkbox-cards.js';\nexport * as CheckboxGroup from './checkbox-group.js';\nexport { Checkbox, type CheckboxProps } from './checkbox.js';\nexport { Code, type CodeProps } from './code.js';\nexport { Container, type ContainerProps } from './container.js';\nexport * as ContextMenu from './context-menu.js';\nexport * as DataList from './data-list.js';\nexport * as Dialog from './dialog.js';\nexport * as DropdownMenu from './dropdown-menu.js';\nexport { Em, type EmProps } from './em.js';\nexport { Flex, type FlexProps } from './flex.js';\nexport { Grid, type GridProps } from './grid.js';\nexport { Heading, type HeadingProps } from './heading.js';\nexport * as HoverCard from './hover-card.js';\nexport { IconButton, type IconButtonProps } from './icon-button.js';\nexport {\n type IconProps,\n ChevronDownIcon,\n ThickCheckIcon,\n ThickChevronRightIcon,\n ThickDividerHorizontalIcon,\n} from './icons.js';\nexport { Inset, type InsetProps } from './inset.js';\nexport { Kbd, type KbdProps } from './kbd.js';\nexport { Link, type LinkProps } from './link.js';\nexport * as Popover from './popover.js';\nexport { Portal, type PortalProps } from './portal.js';\nexport { Progress, type ProgressProps } from './progress.js';\nexport { Quote, type QuoteProps } from './quote.js';\nexport * as RadioCards from './radio-cards.js';\nexport * as RadioGroup from './radio-group.js';\nexport { Radio, type RadioProps } from './radio.js';\nexport { Reset, type ResetProps } from './reset.js';\nexport { ScrollArea, type ScrollAreaProps } from './scroll-area.js';\nexport * as SegmentedControl from './segmented-control.js';\nexport { Section, type SectionProps } from './section.js';\nexport * as Select from './select.js';\nexport { Separator, type SeparatorProps } from './separator.js';\nexport { Skeleton, type SkeletonProps } from './skeleton.js';\nexport { Slider, type SliderProps } from './slider.js';\nexport { Slot, Slottable } from './slot.js';\nexport { Spinner, type SpinnerProps } from './spinner.js';\nexport { Strong, type StrongProps } from './strong.js';\nexport { Switch, type SwitchProps } from './switch.js';\nexport * as TabNav from './tab-nav.js';\nexport * as Table from './table.js';\nexport * as Tabs from './tabs.js';\nexport { TextArea, type TextAreaProps } from './text-area.js';\nexport * as TextField from './text-field.js';\nexport { Text, type TextProps } from './text.js';\nexport { ThemePanel, type ThemePanelProps } from './theme-panel.js';\nexport { Theme, ThemeContext, type ThemeProps, useThemeContext } from './theme.js';\nexport { ToggleButton, type ToggleButtonProps } from './toggle-button.js';\nexport { ToggleIconButton, type ToggleIconButtonProps } from './toggle-icon-button.js';\nexport { Tooltip, type TooltipProps } from './tooltip.js';\nexport { VisuallyHidden, type VisuallyHiddenProps } from './visually-hidden.js';\n"],
|
|
5
|
-
"mappings": "
|
|
6
|
-
"names": ["components_exports", "__export", "AlertDialog", "Callout", "CheckboxCards", "CheckboxGroup", "ContextMenu", "DataList", "Dialog", "DropdownMenu", "HoverCard", "Popover", "RadioCards", "RadioGroup", "SegmentedControl", "Select", "TabNav", "Table", "Tabs", "TextField", "__toCommonJS", "import_accessible_icon", "import_aspect_ratio", "import_avatar", "import_badge", "import_blockquote", "import_box", "import_button", "import_card", "import_checkbox", "import_code", "import_container", "import_em", "import_flex", "import_grid", "import_heading", "import_icon_button", "import_icons", "import_inset", "import_kbd", "import_link", "import_portal", "import_progress", "import_quote", "import_radio", "import_reset", "import_scroll_area", "import_section", "import_separator", "import_skeleton", "import_slider", "import_slot", "import_spinner", "import_strong", "import_switch", "import_text_area", "import_text", "import_theme_panel", "import_theme", "import_toggle_button", "import_toggle_icon_button", "import_tooltip", "import_visually_hidden"]
|
|
4
|
+
"sourcesContent": ["export { AccessibleIcon, type AccessibleIconProps } from './accessible-icon.js';\nexport * as AlertDialog from './alert-dialog.js';\nexport { AspectRatio, type AspectRatioProps } from './aspect-ratio.js';\nexport { Avatar, type AvatarProps } from './avatar.js';\nexport { Badge, type BadgeProps } from './badge.js';\nexport { Blockquote, type BlockquoteProps } from './blockquote.js';\nexport { Box, type BoxProps } from './box.js';\nexport { Button, type ButtonProps } from './button.js';\nexport * as Callout from './callout.js';\nexport { Card, type CardProps } from './card.js';\nexport * as CheckboxCards from './checkbox-cards.js';\nexport * as CheckboxGroup from './checkbox-group.js';\nexport { Checkbox, type CheckboxProps } from './checkbox.js';\nexport { Code, type CodeProps } from './code.js';\nexport { Container, type ContainerProps } from './container.js';\nexport * as ContextMenu from './context-menu.js';\nexport * as DataList from './data-list.js';\nexport * as Dialog from './dialog.js';\nexport * as DropdownMenu from './dropdown-menu.js';\nexport { Em, type EmProps } from './em.js';\nexport { Flex, type FlexProps } from './flex.js';\nexport { Grid, type GridProps } from './grid.js';\nexport { Heading, type HeadingProps } from './heading.js';\nexport * as HoverCard from './hover-card.js';\nexport { IconButton, type IconButtonProps } from './icon-button.js';\nexport {\n type IconProps,\n ChevronDownIcon,\n ThickCheckIcon,\n ThickChevronRightIcon,\n ThickDividerHorizontalIcon,\n} from './icons.js';\nexport { Image, type ImageProps } from './image.js';\nexport { Inset, type InsetProps } from './inset.js';\nexport { Kbd, type KbdProps } from './kbd.js';\nexport { Link, type LinkProps } from './link.js';\nexport * as Popover from './popover.js';\nexport { Portal, type PortalProps } from './portal.js';\nexport { Progress, type ProgressProps } from './progress.js';\nexport { Quote, type QuoteProps } from './quote.js';\nexport * as RadioCards from './radio-cards.js';\nexport * as RadioGroup from './radio-group.js';\nexport { Radio, type RadioProps } from './radio.js';\nexport { Reset, type ResetProps } from './reset.js';\nexport { ScrollArea, type ScrollAreaProps } from './scroll-area.js';\nexport * as SegmentedControl from './segmented-control.js';\nexport { Section, type SectionProps } from './section.js';\nexport * as Select from './select.js';\nexport { Separator, type SeparatorProps } from './separator.js';\nexport { Skeleton, type SkeletonProps } from './skeleton.js';\nexport { Slider, type SliderProps } from './slider.js';\nexport { Slot, Slottable } from './slot.js';\nexport { Spinner, type SpinnerProps } from './spinner.js';\nexport { Strong, type StrongProps } from './strong.js';\nexport { Switch, type SwitchProps } from './switch.js';\nexport * as TabNav from './tab-nav.js';\nexport * as Table from './table.js';\nexport * as Tabs from './tabs.js';\nexport { TextArea, type TextAreaProps } from './text-area.js';\nexport * as TextField from './text-field.js';\nexport { Text, type TextProps } from './text.js';\nexport { ThemePanel, type ThemePanelProps } from './theme-panel.js';\nexport { Theme, ThemeContext, type ThemeProps, useThemeContext } from './theme.js';\nexport { ToggleButton, type ToggleButtonProps } from './toggle-button.js';\nexport { ToggleIconButton, type ToggleIconButtonProps } from './toggle-icon-button.js';\nexport { Tooltip, type TooltipProps } from './tooltip.js';\nexport { VisuallyHidden, type VisuallyHiddenProps } from './visually-hidden.js';\n"],
|
|
5
|
+
"mappings": "gkBAAA,IAAAA,GAAA,GAAAC,GAAAD,GAAA,qDAAAE,GAAA,8IAAAC,GAAA,0DAAAC,GAAA,kBAAAC,GAAA,gGAAAC,GAAA,aAAAC,GAAA,WAAAC,GAAA,iBAAAC,GAAA,gFAAAC,GAAA,0GAAAC,GAAA,+FAAAC,GAAA,eAAAC,GAAA,yFAAAC,GAAA,WAAAC,GAAA,yLAAAC,GAAA,UAAAC,GAAA,SAAAC,GAAA,sDAAAC,GAAA,yZAAAC,GAAApB,IAAA,IAAAqB,EAAyD,gCACzDnB,GAA6B,gCAC7BoB,EAAmD,6BACnDC,EAAyC,uBACzCC,EAAuC,sBACvCC,EAAiD,2BACjDC,EAAmC,oBACnCC,EAAyC,uBACzCxB,GAAyB,2BACzByB,EAAqC,qBACrCxB,GAA+B,kCAC/BC,GAA+B,kCAC/BwB,EAA6C,yBAC7CC,EAAqC,qBACrCC,EAA+C,0BAC/CzB,GAA6B,gCAC7BC,GAA0B,6BAC1BC,GAAwB,0BACxBC,GAA8B,iCAC9BuB,EAAiC,mBACjCC,EAAqC,qBACrCC,EAAqC,qBACrCC,EAA2C,wBAC3CzB,GAA2B,8BAC3B0B,EAAiD,4BACjDC,EAMO,sBACPC,EAAuC,sBACvCC,EAAuC,sBACvCC,EAAmC,oBACnCC,EAAqC,qBACrC9B,GAAyB,2BACzB+B,EAAyC,uBACzCC,EAA6C,yBAC7CC,EAAuC,sBACvChC,GAA4B,+BAC5BC,GAA4B,+BAC5BgC,EAAuC,sBACvCC,EAAuC,sBACvCC,EAAiD,4BACjDjC,GAAkC,qCAClCkC,EAA2C,wBAC3CjC,GAAwB,0BACxBkC,EAA+C,0BAC/CC,EAA6C,yBAC7CC,EAAyC,uBACzCC,EAAgC,qBAChCC,EAA2C,wBAC3CC,EAAyC,uBACzCC,EAAyC,uBACzCvC,GAAwB,2BACxBC,GAAuB,yBACvBC,GAAsB,wBACtBsC,EAA6C,0BAC7CrC,GAA2B,8BAC3BsC,EAAqC,qBACrCC,EAAiD,4BACjDC,EAAsE,sBACtEC,EAAqD,8BACrDC,EAA6D,mCAC7DC,EAA2C,wBAC3CC,EAAyD",
|
|
6
|
+
"names": ["components_exports", "__export", "AlertDialog", "Callout", "CheckboxCards", "CheckboxGroup", "ContextMenu", "DataList", "Dialog", "DropdownMenu", "HoverCard", "Popover", "RadioCards", "RadioGroup", "SegmentedControl", "Select", "TabNav", "Table", "Tabs", "TextField", "__toCommonJS", "import_accessible_icon", "import_aspect_ratio", "import_avatar", "import_badge", "import_blockquote", "import_box", "import_button", "import_card", "import_checkbox", "import_code", "import_container", "import_em", "import_flex", "import_grid", "import_heading", "import_icon_button", "import_icons", "import_image", "import_inset", "import_kbd", "import_link", "import_portal", "import_progress", "import_quote", "import_radio", "import_reset", "import_scroll_area", "import_section", "import_separator", "import_skeleton", "import_slider", "import_slot", "import_spinner", "import_strong", "import_switch", "import_text_area", "import_text", "import_theme_panel", "import_theme", "import_toggle_button", "import_toggle_icon_button", "import_tooltip", "import_visually_hidden"]
|
|
7
7
|
}
|
|
@@ -9,6 +9,7 @@ export * from './leading-trim.prop.js';
|
|
|
9
9
|
export * from './margin.props.js';
|
|
10
10
|
export * from './padding.props.js';
|
|
11
11
|
export * from './radius.prop.js';
|
|
12
|
+
export * from './shadow.props.js';
|
|
12
13
|
export * from './text-align.prop.js';
|
|
13
14
|
export * from './text-wrap.prop.js';
|
|
14
15
|
export * from './truncate.prop.js';
|
|
@@ -37,6 +38,7 @@ export * from '../components/grid.props.js';
|
|
|
37
38
|
export * from '../components/heading.props.js';
|
|
38
39
|
export * from '../components/hover-card.props.js';
|
|
39
40
|
export * from '../components/icon-button.props.js';
|
|
41
|
+
export * from '../components/image.props.js';
|
|
40
42
|
export * from '../components/inset.props.js';
|
|
41
43
|
export * from '../components/kbd.props.js';
|
|
42
44
|
export * from '../components/link.props.js';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/props/index.ts"],"names":[],"mappings":"AACA,cAAc,eAAe,CAAC;AAG9B,cAAc,oBAAoB,CAAC;AACnC,cAAc,iBAAiB,CAAC;AAChC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,mBAAmB,CAAC;AAClC,cAAc,yBAAyB,CAAC;AACxC,cAAc,mBAAmB,CAAC;AAClC,cAAc,wBAAwB,CAAC;AACvC,cAAc,mBAAmB,CAAC;AAClC,cAAc,oBAAoB,CAAC;AACnC,cAAc,kBAAkB,CAAC;AACjC,cAAc,sBAAsB,CAAC;AACrC,cAAc,qBAAqB,CAAC;AACpC,cAAc,oBAAoB,CAAC;AACnC,cAAc,kBAAkB,CAAC;AACjC,cAAc,kBAAkB,CAAC;AAGjC,cAAc,qCAAqC,CAAC;AACpD,cAAc,+BAA+B,CAAC;AAC9C,cAAc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B,CAAC;AAC7C,cAAc,8BAA8B,CAAC;AAC7C,cAAc,4BAA4B,CAAC;AAC3C,cAAc,6BAA6B,CAAC;AAC5C,cAAc,gCAAgC,CAAC;AAC/C,cAAc,iCAAiC,CAAC;AAChD,cAAc,8BAA8B,CAAC;AAC7C,cAAc,8BAA8B,CAAC;AAC7C,cAAc,oCAAoC,CAAC;AACnD,cAAc,oCAAoC,CAAC;AACnD,cAAc,oCAAoC,CAAC;AACnD,cAAc,gCAAgC,CAAC;AAC/C,cAAc,0CAA0C,CAAC;AACzD,cAAc,+BAA+B,CAAC;AAC9C,cAAc,kCAAkC,CAAC;AACjD,cAAc,iCAAiC,CAAC;AAChD,cAAc,+BAA+B,CAAC;AAC9C,cAAc,gCAAgC,CAAC;AAC/C,cAAc,+BAA+B,CAAC;AAC9C,cAAc,+BAA+B,CAAC;AAC9C,cAAc,gCAAgC,CAAC;AAC/C,cAAc,8BAA8B,CAAC;AAC7C,cAAc,6BAA6B,CAAC;AAC5C,cAAc,kCAAkC,CAAC;AACjD,cAAc,mCAAmC,CAAC;AAClD,cAAc,6BAA6B,CAAC;AAC5C,cAAc,8BAA8B,CAAC;AAC7C,cAAc,gCAAgC,CAAC"}
|
package/dist/cjs/props/index.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";var a=Object.defineProperty;var b=Object.getOwnPropertyDescriptor;var c=Object.getOwnPropertyNames;var d=Object.prototype.hasOwnProperty;var t=(f,e,p,x)=>{if(e&&typeof e=="object"||typeof e=="function")for(let m of c(e))!d.call(f,m)&&m!==p&&a(f,m,{get:()=>e[m],enumerable:!(x=b(e,m))||x.enumerable});return f},r=(f,e,p)=>(t(f,e,"default"),p&&t(p,e,"default"));var g=f=>t(a({},"__esModule",{value:!0}),f);var o={};module.exports=g(o);r(o,require("./prop-def.js"),module.exports);r(o,require("./as-child.prop.js"),module.exports);r(o,require("./color.prop.js"),module.exports);r(o,require("./gap.props.js"),module.exports);r(o,require("./height.props.js"),module.exports);r(o,require("./high-contrast.prop.js"),module.exports);r(o,require("./layout.props.js"),module.exports);r(o,require("./leading-trim.prop.js"),module.exports);r(o,require("./margin.props.js"),module.exports);r(o,require("./padding.props.js"),module.exports);r(o,require("./radius.prop.js"),module.exports);r(o,require("./text-align.prop.js"),module.exports);r(o,require("./text-wrap.prop.js"),module.exports);r(o,require("./truncate.prop.js"),module.exports);r(o,require("./weight.prop.js"),module.exports);r(o,require("./width.props.js"),module.exports);r(o,require("../components/alert-dialog.props.js"),module.exports);r(o,require("../components/avatar.props.js"),module.exports);r(o,require("../components/badge.props.js"),module.exports);r(o,require("../components/blockquote.props.js"),module.exports);r(o,require("../components/box.props.js"),module.exports);r(o,require("../components/button.props.js"),module.exports);r(o,require("../components/callout.props.js"),module.exports);r(o,require("../components/card.props.js"),module.exports);r(o,require("../components/checkbox-cards.props.js"),module.exports);r(o,require("../components/checkbox-group.props.js"),module.exports);r(o,require("../components/checkbox.props.js"),module.exports);r(o,require("../components/code.props.js"),module.exports);r(o,require("../components/container.props.js"),module.exports);r(o,require("../components/context-menu.props.js"),module.exports);r(o,require("../components/data-list.props.js"),module.exports);r(o,require("../components/dialog.props.js"),module.exports);r(o,require("../components/dropdown-menu.props.js"),module.exports);r(o,require("../components/em.props.js"),module.exports);r(o,require("../components/flex.props.js"),module.exports);r(o,require("../components/grid.props.js"),module.exports);r(o,require("../components/heading.props.js"),module.exports);r(o,require("../components/hover-card.props.js"),module.exports);r(o,require("../components/icon-button.props.js"),module.exports);r(o,require("../components/inset.props.js"),module.exports);r(o,require("../components/kbd.props.js"),module.exports);r(o,require("../components/link.props.js"),module.exports);r(o,require("../components/popover.props.js"),module.exports);r(o,require("../components/progress.props.js"),module.exports);r(o,require("../components/quote.props.js"),module.exports);r(o,require("../components/radio.props.js"),module.exports);r(o,require("../components/radio-cards.props.js"),module.exports);r(o,require("../components/radio-group.props.js"),module.exports);r(o,require("../components/scroll-area.props.js"),module.exports);r(o,require("../components/section.props.js"),module.exports);r(o,require("../components/segmented-control.props.js"),module.exports);r(o,require("../components/select.props.js"),module.exports);r(o,require("../components/separator.props.js"),module.exports);r(o,require("../components/skeleton.props.js"),module.exports);r(o,require("../components/slider.props.js"),module.exports);r(o,require("../components/spinner.props.js"),module.exports);r(o,require("../components/strong.props.js"),module.exports);r(o,require("../components/switch.props.js"),module.exports);r(o,require("../components/tab-nav.props.js"),module.exports);r(o,require("../components/table.props.js"),module.exports);r(o,require("../components/tabs.props.js"),module.exports);r(o,require("../components/text-area.props.js"),module.exports);r(o,require("../components/text-field.props.js"),module.exports);r(o,require("../components/text.props.js"),module.exports);r(o,require("../components/theme.props.js"),module.exports);r(o,require("../components/tooltip.props.js"),module.exports);
|
|
1
|
+
"use strict";var a=Object.defineProperty;var b=Object.getOwnPropertyDescriptor;var c=Object.getOwnPropertyNames;var d=Object.prototype.hasOwnProperty;var t=(f,e,p,x)=>{if(e&&typeof e=="object"||typeof e=="function")for(let m of c(e))!d.call(f,m)&&m!==p&&a(f,m,{get:()=>e[m],enumerable:!(x=b(e,m))||x.enumerable});return f},r=(f,e,p)=>(t(f,e,"default"),p&&t(p,e,"default"));var g=f=>t(a({},"__esModule",{value:!0}),f);var o={};module.exports=g(o);r(o,require("./prop-def.js"),module.exports);r(o,require("./as-child.prop.js"),module.exports);r(o,require("./color.prop.js"),module.exports);r(o,require("./gap.props.js"),module.exports);r(o,require("./height.props.js"),module.exports);r(o,require("./high-contrast.prop.js"),module.exports);r(o,require("./layout.props.js"),module.exports);r(o,require("./leading-trim.prop.js"),module.exports);r(o,require("./margin.props.js"),module.exports);r(o,require("./padding.props.js"),module.exports);r(o,require("./radius.prop.js"),module.exports);r(o,require("./shadow.props.js"),module.exports);r(o,require("./text-align.prop.js"),module.exports);r(o,require("./text-wrap.prop.js"),module.exports);r(o,require("./truncate.prop.js"),module.exports);r(o,require("./weight.prop.js"),module.exports);r(o,require("./width.props.js"),module.exports);r(o,require("../components/alert-dialog.props.js"),module.exports);r(o,require("../components/avatar.props.js"),module.exports);r(o,require("../components/badge.props.js"),module.exports);r(o,require("../components/blockquote.props.js"),module.exports);r(o,require("../components/box.props.js"),module.exports);r(o,require("../components/button.props.js"),module.exports);r(o,require("../components/callout.props.js"),module.exports);r(o,require("../components/card.props.js"),module.exports);r(o,require("../components/checkbox-cards.props.js"),module.exports);r(o,require("../components/checkbox-group.props.js"),module.exports);r(o,require("../components/checkbox.props.js"),module.exports);r(o,require("../components/code.props.js"),module.exports);r(o,require("../components/container.props.js"),module.exports);r(o,require("../components/context-menu.props.js"),module.exports);r(o,require("../components/data-list.props.js"),module.exports);r(o,require("../components/dialog.props.js"),module.exports);r(o,require("../components/dropdown-menu.props.js"),module.exports);r(o,require("../components/em.props.js"),module.exports);r(o,require("../components/flex.props.js"),module.exports);r(o,require("../components/grid.props.js"),module.exports);r(o,require("../components/heading.props.js"),module.exports);r(o,require("../components/hover-card.props.js"),module.exports);r(o,require("../components/icon-button.props.js"),module.exports);r(o,require("../components/image.props.js"),module.exports);r(o,require("../components/inset.props.js"),module.exports);r(o,require("../components/kbd.props.js"),module.exports);r(o,require("../components/link.props.js"),module.exports);r(o,require("../components/popover.props.js"),module.exports);r(o,require("../components/progress.props.js"),module.exports);r(o,require("../components/quote.props.js"),module.exports);r(o,require("../components/radio.props.js"),module.exports);r(o,require("../components/radio-cards.props.js"),module.exports);r(o,require("../components/radio-group.props.js"),module.exports);r(o,require("../components/scroll-area.props.js"),module.exports);r(o,require("../components/section.props.js"),module.exports);r(o,require("../components/segmented-control.props.js"),module.exports);r(o,require("../components/select.props.js"),module.exports);r(o,require("../components/separator.props.js"),module.exports);r(o,require("../components/skeleton.props.js"),module.exports);r(o,require("../components/slider.props.js"),module.exports);r(o,require("../components/spinner.props.js"),module.exports);r(o,require("../components/strong.props.js"),module.exports);r(o,require("../components/switch.props.js"),module.exports);r(o,require("../components/tab-nav.props.js"),module.exports);r(o,require("../components/table.props.js"),module.exports);r(o,require("../components/tabs.props.js"),module.exports);r(o,require("../components/text-area.props.js"),module.exports);r(o,require("../components/text-field.props.js"),module.exports);r(o,require("../components/text.props.js"),module.exports);r(o,require("../components/theme.props.js"),module.exports);r(o,require("../components/tooltip.props.js"),module.exports);
|
|
2
2
|
//# sourceMappingURL=index.js.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../src/props/index.ts"],
|
|
4
|
-
"sourcesContent": ["// Prop definition\nexport * from './prop-def.js';\n\n// Individual props\nexport * from './as-child.prop.js';\nexport * from './color.prop.js';\nexport * from './gap.props.js';\nexport * from './height.props.js';\nexport * from './high-contrast.prop.js';\nexport * from './layout.props.js';\nexport * from './leading-trim.prop.js';\nexport * from './margin.props.js';\nexport * from './padding.props.js';\nexport * from './radius.prop.js';\nexport * from './text-align.prop.js';\nexport * from './text-wrap.prop.js';\nexport * from './truncate.prop.js';\nexport * from './weight.prop.js';\nexport * from './width.props.js';\n\n// Component props\nexport * from '../components/alert-dialog.props.js';\nexport * from '../components/avatar.props.js';\nexport * from '../components/badge.props.js';\nexport * from '../components/blockquote.props.js';\nexport * from '../components/box.props.js';\nexport * from '../components/button.props.js';\nexport * from '../components/callout.props.js';\nexport * from '../components/card.props.js';\nexport * from '../components/checkbox-cards.props.js';\nexport * from '../components/checkbox-group.props.js';\nexport * from '../components/checkbox.props.js';\nexport * from '../components/code.props.js';\nexport * from '../components/container.props.js';\nexport * from '../components/context-menu.props.js';\nexport * from '../components/data-list.props.js';\nexport * from '../components/dialog.props.js';\nexport * from '../components/dropdown-menu.props.js';\nexport * from '../components/em.props.js';\nexport * from '../components/flex.props.js';\nexport * from '../components/grid.props.js';\nexport * from '../components/heading.props.js';\nexport * from '../components/hover-card.props.js';\nexport * from '../components/icon-button.props.js';\nexport * from '../components/inset.props.js';\nexport * from '../components/kbd.props.js';\nexport * from '../components/link.props.js';\nexport * from '../components/popover.props.js';\nexport * from '../components/progress.props.js';\nexport * from '../components/quote.props.js';\nexport * from '../components/radio.props.js';\nexport * from '../components/radio-cards.props.js';\nexport * from '../components/radio-group.props.js';\nexport * from '../components/scroll-area.props.js';\nexport * from '../components/section.props.js';\nexport * from '../components/segmented-control.props.js';\nexport * from '../components/select.props.js';\nexport * from '../components/separator.props.js';\nexport * from '../components/skeleton.props.js';\nexport * from '../components/slider.props.js';\nexport * from '../components/spinner.props.js';\nexport * from '../components/strong.props.js';\nexport * from '../components/switch.props.js';\nexport * from '../components/tab-nav.props.js';\nexport * from '../components/table.props.js';\nexport * from '../components/tabs.props.js';\nexport * from '../components/text-area.props.js';\nexport * from '../components/text-field.props.js';\nexport * from '../components/text.props.js';\nexport * from '../components/theme.props.js';\nexport * from '../components/tooltip.props.js';\n"],
|
|
5
|
-
"mappings": "iaAAA,IAAAA,EAAA,kBAAAC,EAAAD,GACAE,EAAAF,EAAc,yBADd,gBAIAE,EAAAF,EAAc,8BAJd,gBAKAE,EAAAF,EAAc,2BALd,gBAMAE,EAAAF,EAAc,0BANd,gBAOAE,EAAAF,EAAc,6BAPd,gBAQAE,EAAAF,EAAc,mCARd,gBASAE,EAAAF,EAAc,6BATd,gBAUAE,EAAAF,EAAc,kCAVd,gBAWAE,EAAAF,EAAc,6BAXd,gBAYAE,EAAAF,EAAc,8BAZd,gBAaAE,EAAAF,EAAc,4BAbd,gBAcAE,EAAAF,EAAc,
|
|
4
|
+
"sourcesContent": ["// Prop definition\nexport * from './prop-def.js';\n\n// Individual props\nexport * from './as-child.prop.js';\nexport * from './color.prop.js';\nexport * from './gap.props.js';\nexport * from './height.props.js';\nexport * from './high-contrast.prop.js';\nexport * from './layout.props.js';\nexport * from './leading-trim.prop.js';\nexport * from './margin.props.js';\nexport * from './padding.props.js';\nexport * from './radius.prop.js';\nexport * from './shadow.props.js';\nexport * from './text-align.prop.js';\nexport * from './text-wrap.prop.js';\nexport * from './truncate.prop.js';\nexport * from './weight.prop.js';\nexport * from './width.props.js';\n\n// Component props\nexport * from '../components/alert-dialog.props.js';\nexport * from '../components/avatar.props.js';\nexport * from '../components/badge.props.js';\nexport * from '../components/blockquote.props.js';\nexport * from '../components/box.props.js';\nexport * from '../components/button.props.js';\nexport * from '../components/callout.props.js';\nexport * from '../components/card.props.js';\nexport * from '../components/checkbox-cards.props.js';\nexport * from '../components/checkbox-group.props.js';\nexport * from '../components/checkbox.props.js';\nexport * from '../components/code.props.js';\nexport * from '../components/container.props.js';\nexport * from '../components/context-menu.props.js';\nexport * from '../components/data-list.props.js';\nexport * from '../components/dialog.props.js';\nexport * from '../components/dropdown-menu.props.js';\nexport * from '../components/em.props.js';\nexport * from '../components/flex.props.js';\nexport * from '../components/grid.props.js';\nexport * from '../components/heading.props.js';\nexport * from '../components/hover-card.props.js';\nexport * from '../components/icon-button.props.js';\nexport * from '../components/image.props.js';\nexport * from '../components/inset.props.js';\nexport * from '../components/kbd.props.js';\nexport * from '../components/link.props.js';\nexport * from '../components/popover.props.js';\nexport * from '../components/progress.props.js';\nexport * from '../components/quote.props.js';\nexport * from '../components/radio.props.js';\nexport * from '../components/radio-cards.props.js';\nexport * from '../components/radio-group.props.js';\nexport * from '../components/scroll-area.props.js';\nexport * from '../components/section.props.js';\nexport * from '../components/segmented-control.props.js';\nexport * from '../components/select.props.js';\nexport * from '../components/separator.props.js';\nexport * from '../components/skeleton.props.js';\nexport * from '../components/slider.props.js';\nexport * from '../components/spinner.props.js';\nexport * from '../components/strong.props.js';\nexport * from '../components/switch.props.js';\nexport * from '../components/tab-nav.props.js';\nexport * from '../components/table.props.js';\nexport * from '../components/tabs.props.js';\nexport * from '../components/text-area.props.js';\nexport * from '../components/text-field.props.js';\nexport * from '../components/text.props.js';\nexport * from '../components/theme.props.js';\nexport * from '../components/tooltip.props.js';\n"],
|
|
5
|
+
"mappings": "iaAAA,IAAAA,EAAA,kBAAAC,EAAAD,GACAE,EAAAF,EAAc,yBADd,gBAIAE,EAAAF,EAAc,8BAJd,gBAKAE,EAAAF,EAAc,2BALd,gBAMAE,EAAAF,EAAc,0BANd,gBAOAE,EAAA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E,EAAAF,EAAc,0CAjDd,gBAkDAE,EAAAF,EAAc,2CAlDd,gBAmDAE,EAAAF,EAAc,wCAnDd,gBAoDAE,EAAAF,EAAc,wCApDd,gBAqDAE,EAAAF,EAAc,8CArDd,gBAsDAE,EAAAF,EAAc,8CAtDd,gBAuDAE,EAAAF,EAAc,8CAvDd,gBAwDAE,EAAAF,EAAc,0CAxDd,gBAyDAE,EAAAF,EAAc,oDAzDd,gBA0DAE,EAAAF,EAAc,yCA1Dd,gBA2DAE,EAAAF,EAAc,4CA3Dd,gBA4DAE,EAAAF,EAAc,2CA5Dd,gBA6DAE,EAAAF,EAAc,yCA7Dd,gBA8DAE,EAAAF,EAAc,0CA9Dd,gBA+DAE,EAAAF,EAAc,yCA/Dd,gBAgEAE,EAAAF,EAAc,yCAhEd,gBAiEAE,EAAAF,EAAc,0CAjEd,gBAkEAE,EAAAF,EAAc,wCAlEd,gBAmEAE,EAAAF,EAAc,uCAnEd,gBAoEAE,EAAAF,EAAc,4CApEd,gBAqEAE,EAAAF,EAAc,6CArEd,gBAsEAE,EAAAF,EAAc,uCAtEd,gBAuEAE,EAAAF,EAAc,wCAvEd,gBAwEAE,EAAAF,EAAc,0CAxEd",
|
|
6
6
|
"names": ["props_exports", "__toCommonJS", "__reExport"]
|
|
7
7
|
}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import type { GetPropDefTypes } from './prop-def.js';
|
|
2
|
+
declare const shadowPropDefs: {
|
|
3
|
+
/**
|
|
4
|
+
* Sets the CSS **box-shadow** property using design system shadow tokens.
|
|
5
|
+
* Supports shadow scale values and responsive objects.
|
|
6
|
+
*
|
|
7
|
+
* @example
|
|
8
|
+
* shadow="3"
|
|
9
|
+
* shadow={{ sm: '2', lg: '4' }}
|
|
10
|
+
*
|
|
11
|
+
* @link
|
|
12
|
+
* https://developer.mozilla.org/en-US/docs/Web/CSS/box-shadow
|
|
13
|
+
*/
|
|
14
|
+
shadow: {
|
|
15
|
+
type: "enum";
|
|
16
|
+
className: string;
|
|
17
|
+
values: readonly ["1", "2", "3", "4", "5", "6"];
|
|
18
|
+
responsive: true;
|
|
19
|
+
};
|
|
20
|
+
};
|
|
21
|
+
type ShadowProps = GetPropDefTypes<typeof shadowPropDefs>;
|
|
22
|
+
export { shadowPropDefs };
|
|
23
|
+
export type { ShadowProps };
|
|
24
|
+
//# sourceMappingURL=shadow.props.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"shadow.props.d.ts","sourceRoot":"","sources":["../../../src/props/shadow.props.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAW,eAAe,EAAE,MAAM,eAAe,CAAC;AAI9D,QAAA,MAAM,cAAc;IAClB;;;;;;;;;;OAUG;;;;;;;CASJ,CAAC;AAEF,KAAK,WAAW,GAAG,eAAe,CAAC,OAAO,cAAc,CAAC,CAAC;AAE1D,OAAO,EAAE,cAAc,EAAE,CAAC;AAC1B,YAAY,EAAE,WAAW,EAAE,CAAC"}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
"use strict";var r=Object.defineProperty;var f=Object.getOwnPropertyDescriptor;var d=Object.getOwnPropertyNames;var h=Object.prototype.hasOwnProperty;var w=(o,e)=>{for(var p in e)r(o,p,{get:e[p],enumerable:!0})},y=(o,e,p,t)=>{if(e&&typeof e=="object"||typeof e=="function")for(let s of d(e))!h.call(o,s)&&s!==p&&r(o,s,{get:()=>e[s],enumerable:!(t=f(e,s))||t.enumerable});return o};var P=o=>y(r({},"__esModule",{value:!0}),o);var u={};w(u,{shadowPropDefs:()=>a});module.exports=P(u);const n=["1","2","3","4","5","6"],a={shadow:{type:"enum",className:"rt-r-shadow",values:n,responsive:!0}};
|
|
2
|
+
//# sourceMappingURL=shadow.props.js.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../src/props/shadow.props.ts"],
|
|
4
|
+
"sourcesContent": ["import type { PropDef, GetPropDefTypes } from './prop-def.js';\n\nconst shadowValues = ['1', '2', '3', '4', '5', '6'] as const;\n\nconst shadowPropDefs = {\n /**\n * Sets the CSS **box-shadow** property using design system shadow tokens.\n * Supports shadow scale values and responsive objects.\n *\n * @example\n * shadow=\"3\"\n * shadow={{ sm: '2', lg: '4' }}\n *\n * @link\n * https://developer.mozilla.org/en-US/docs/Web/CSS/box-shadow\n */\n shadow: {\n type: 'enum',\n className: 'rt-r-shadow',\n values: shadowValues,\n responsive: true,\n },\n} satisfies {\n shadow: PropDef<(typeof shadowValues)[number]>;\n};\n\ntype ShadowProps = GetPropDefTypes<typeof shadowPropDefs>;\n\nexport { shadowPropDefs };\nexport type { ShadowProps };\n"],
|
|
5
|
+
"mappings": "yaAAA,IAAAA,EAAA,GAAAC,EAAAD,EAAA,oBAAAE,IAAA,eAAAC,EAAAH,GAEA,MAAMI,EAAe,CAAC,IAAK,IAAK,IAAK,IAAK,IAAK,GAAG,EAE5CF,EAAiB,CAYrB,OAAQ,CACN,KAAM,OACN,UAAW,cACX,OAAQE,EACR,WAAY,EACd,CACF",
|
|
6
|
+
"names": ["shadow_props_exports", "__export", "shadowPropDefs", "__toCommonJS", "shadowValues"]
|
|
7
|
+
}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
import { imagePropDefs } from './image.props.js';
|
|
3
|
+
import type { ComponentPropsWithout, RemovedProps } from '../helpers/component-props.js';
|
|
4
|
+
import type { MarginProps } from '../props/margin.props.js';
|
|
5
|
+
import type { WidthProps } from '../props/width.props.js';
|
|
6
|
+
import type { HeightProps } from '../props/height.props.js';
|
|
7
|
+
import type { GetPropDefTypes } from '../props/prop-def.js';
|
|
8
|
+
type ImageOwnProps = GetPropDefTypes<typeof imagePropDefs> & {
|
|
9
|
+
loading?: 'eager' | 'lazy';
|
|
10
|
+
};
|
|
11
|
+
interface ImageProps extends ComponentPropsWithout<'img', RemovedProps | 'color' | 'width' | 'height' | 'alt'>, MarginProps, WidthProps, HeightProps, ImageOwnProps {
|
|
12
|
+
/**
|
|
13
|
+
* The alt attribute provides alternative information for an image if a user for some reason cannot view it.
|
|
14
|
+
* Required for accessibility when not using asChild.
|
|
15
|
+
*/
|
|
16
|
+
alt?: string;
|
|
17
|
+
}
|
|
18
|
+
declare const Image: React.ForwardRefExoticComponent<ImageProps & React.RefAttributes<HTMLImageElement>>;
|
|
19
|
+
export { Image };
|
|
20
|
+
export type { ImageProps };
|
|
21
|
+
//# sourceMappingURL=image.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"image.d.ts","sourceRoot":"","sources":["../../../src/components/image.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAG/B,OAAO,EAAE,aAAa,EAAE,MAAM,kBAAkB,CAAC;AAMjD,OAAO,KAAK,EAAE,qBAAqB,EAAE,YAAY,EAAE,MAAM,+BAA+B,CAAC;AACzF,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,0BAA0B,CAAC;AAC5D,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,yBAAyB,CAAC;AAC1D,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,0BAA0B,CAAC;AAC5D,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,sBAAsB,CAAC;AAG5D,KAAK,aAAa,GAAG,eAAe,CAAC,OAAO,aAAa,CAAC,GAAG;IAC3D,OAAO,CAAC,EAAE,OAAO,GAAG,MAAM,CAAC;CAC5B,CAAC;AAEF,UAAU,UACR,SAAQ,qBAAqB,CAAC,KAAK,EAAE,YAAY,GAAG,OAAO,GAAG,OAAO,GAAG,QAAQ,GAAG,KAAK,CAAC,EACvF,WAAW,EACX,UAAU,EACV,WAAW,EACX,aAAa;IACf;;;OAGG;IACH,GAAG,CAAC,EAAE,MAAM,CAAC;CACd;AAED,QAAA,MAAM,KAAK,qFAsJT,CAAC;AAIH,OAAO,EAAE,KAAK,EAAE,CAAC;AACjB,YAAY,EAAE,UAAU,EAAE,CAAC"}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
"use client";import*as e from"react";import r from"classnames";import{imagePropDefs as h}from"./image.props.js";import{extractProps as I}from"../helpers/extract-props.js";import{marginPropDefs as P}from"../props/margin.props.js";import{widthPropDefs as b}from"../props/width.props.js";import{heightPropDefs as N}from"../props/height.props.js";const u=e.forwardRef((d,n)=>{const{variant:m="surface",fit:v="cover",children:c}=d,{asChild:y,className:o,radius:s,style:a,loading:i="lazy",alt:g,src:p,children:x,...l}=I(d,h,P,b,N),f=e.createElement("img",{"data-radius":s,loading:i,style:a,className:r("rt-reset","rt-Image",m==="blur"&&"rt-Image--blur",o),alt:g,src:p,...l,ref:n});if(y&&c){const t=e.Children.only(c);return m==="blur"?e.cloneElement(t,{className:r(t.props?.className,"rt-variant-blur"),style:{position:"relative",display:"inline-block",textDecoration:"none",color:"inherit",border:"none",background:"none",padding:0,font:"inherit",cursor:"pointer",...t.props?.style},children:e.createElement(e.Fragment,null,e.createElement("img",{"data-radius":s,loading:i,style:{...a,position:"absolute",top:"8px",left:"0"},className:r("rt-reset","rt-Image","rt-Image--blur","rt-Image--blur-bg",o),alt:"",src:p,...l}),e.createElement("img",{"data-radius":s,loading:i,style:{...a,position:"relative",zIndex:1},className:r("rt-reset","rt-Image","rt-Image--blur",o),alt:g,src:p,...l,ref:n}))}):e.cloneElement(t,{className:r(t.props?.className,"rt-Image"),style:{textDecoration:"none",color:"inherit",border:"none",background:"none",padding:0,font:"inherit",cursor:"pointer",...t.props?.style},children:f})}return m==="blur"?e.createElement("div",{className:"rt-variant-blur",style:{position:"relative",display:"inline-block"}},e.createElement("img",{"data-radius":s,loading:i,style:{...a,position:"absolute",top:"8px",left:"0"},className:r("rt-reset","rt-Image","rt-Image--blur","rt-Image--blur-bg",o),alt:"",src:p,...l}),e.createElement("img",{"data-radius":s,loading:i,style:{...a,position:"relative",zIndex:1},className:r("rt-reset","rt-Image","rt-Image--blur",o),alt:g,src:p,...l,ref:n})):f});u.displayName="Image";export{u as Image};
|
|
2
|
+
//# sourceMappingURL=image.js.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../src/components/image.tsx"],
|
|
4
|
+
"sourcesContent": ["'use client';\n\nimport * as React from 'react';\nimport classNames from 'classnames';\n\nimport { imagePropDefs } from './image.props.js';\nimport { extractProps } from '../helpers/extract-props.js';\nimport { marginPropDefs } from '../props/margin.props.js';\nimport { widthPropDefs } from '../props/width.props.js';\nimport { heightPropDefs } from '../props/height.props.js';\n\nimport type { ComponentPropsWithout, RemovedProps } from '../helpers/component-props.js';\nimport type { MarginProps } from '../props/margin.props.js';\nimport type { WidthProps } from '../props/width.props.js';\nimport type { HeightProps } from '../props/height.props.js';\nimport type { GetPropDefTypes } from '../props/prop-def.js';\n\ntype ImageElement = React.ElementRef<'img'>;\ntype ImageOwnProps = GetPropDefTypes<typeof imagePropDefs> & {\n loading?: 'eager' | 'lazy';\n};\n\ninterface ImageProps\n extends ComponentPropsWithout<'img', RemovedProps | 'color' | 'width' | 'height' | 'alt'>,\n MarginProps,\n WidthProps,\n HeightProps,\n ImageOwnProps {\n /**\n * The alt attribute provides alternative information for an image if a user for some reason cannot view it.\n * Required for accessibility when not using asChild.\n */\n alt?: string;\n}\n\nconst Image = React.forwardRef<ImageElement, ImageProps>((props, forwardedRef) => {\n const { variant = 'surface', fit = 'cover', children } = props;\n const {\n asChild,\n className,\n radius,\n style,\n loading = 'lazy',\n alt,\n src,\n children: _children, // Extract children to exclude from imgProps\n ...imgProps\n } = extractProps(props, imagePropDefs, marginPropDefs, widthPropDefs, heightPropDefs);\n\n // Create the standard img element\n const imgElement = (\n <img\n data-radius={radius}\n loading={loading}\n style={style}\n className={classNames(\n 'rt-reset',\n 'rt-Image',\n variant === 'blur' && 'rt-Image--blur',\n className,\n )}\n alt={alt}\n src={src}\n {...imgProps}\n ref={forwardedRef}\n />\n );\n\n // Handle asChild - inject img into the child element\n if (asChild && children) {\n const child = React.Children.only(children) as React.ReactElement<any>;\n\n if (variant === 'blur') {\n // For blur variant with asChild\n return React.cloneElement(child, {\n className: classNames(child.props?.className, 'rt-variant-blur'),\n style: {\n position: 'relative',\n display: 'inline-block',\n textDecoration: 'none', // Reset link underlines\n color: 'inherit', // Reset link colors\n border: 'none', // Reset button borders\n background: 'none', // Reset button backgrounds\n padding: 0, // Reset button padding\n font: 'inherit', // Reset button fonts\n cursor: 'pointer', // Ensure interactive cursor\n ...child.props?.style,\n },\n children: (\n <>\n {/* Background blurred image */}\n <img\n data-radius={radius}\n loading={loading}\n style={{\n ...style,\n position: 'absolute',\n top: '8px',\n left: '0',\n }}\n className={classNames(\n 'rt-reset',\n 'rt-Image',\n 'rt-Image--blur',\n 'rt-Image--blur-bg',\n className,\n )}\n alt=\"\"\n src={src}\n {...imgProps}\n />\n {/* Foreground image */}\n <img\n data-radius={radius}\n loading={loading}\n style={{ ...style, position: 'relative', zIndex: 1 }}\n className={classNames('rt-reset', 'rt-Image', 'rt-Image--blur', className)}\n alt={alt}\n src={src}\n {...imgProps}\n ref={forwardedRef}\n />\n </>\n ),\n });\n } else {\n // For surface variant with asChild\n return React.cloneElement(child, {\n className: classNames(child.props?.className, 'rt-Image'),\n style: {\n textDecoration: 'none', // Reset link underlines\n color: 'inherit', // Reset link colors\n border: 'none', // Reset button borders\n background: 'none', // Reset button backgrounds\n padding: 0, // Reset button padding\n font: 'inherit', // Reset button fonts\n cursor: 'pointer', // Ensure interactive cursor\n ...child.props?.style, // Allow user overrides\n },\n children: imgElement,\n });\n }\n }\n\n // Regular rendering without asChild\n if (variant === 'blur') {\n return (\n <div className=\"rt-variant-blur\" style={{ position: 'relative', display: 'inline-block' }}>\n {/* Background blurred image */}\n <img\n data-radius={radius}\n loading={loading}\n style={{\n ...style,\n position: 'absolute',\n top: '8px',\n left: '0',\n }}\n className={classNames(\n 'rt-reset',\n 'rt-Image',\n 'rt-Image--blur',\n 'rt-Image--blur-bg',\n className,\n )}\n alt=\"\"\n src={src}\n {...imgProps}\n />\n {/* Foreground image */}\n <img\n data-radius={radius}\n loading={loading}\n style={{ ...style, position: 'relative', zIndex: 1 }}\n className={classNames('rt-reset', 'rt-Image', 'rt-Image--blur', className)}\n alt={alt}\n src={src}\n {...imgProps}\n ref={forwardedRef}\n />\n </div>\n );\n }\n\n return imgElement;\n});\n\nImage.displayName = 'Image';\n\nexport { Image };\nexport type { ImageProps };\n"],
|
|
5
|
+
"mappings": "aAEA,UAAYA,MAAW,QACvB,OAAOC,MAAgB,aAEvB,OAAS,iBAAAC,MAAqB,mBAC9B,OAAS,gBAAAC,MAAoB,8BAC7B,OAAS,kBAAAC,MAAsB,2BAC/B,OAAS,iBAAAC,MAAqB,0BAC9B,OAAS,kBAAAC,MAAsB,2BA0B/B,MAAMC,EAAQP,EAAM,WAAqC,CAACQ,EAAOC,IAAiB,CAChF,KAAM,CAAE,QAAAC,EAAU,UAAW,IAAAC,EAAM,QAAS,SAAAC,CAAS,EAAIJ,EACnD,CACJ,QAAAK,EACA,UAAAC,EACA,OAAAC,EACA,MAAAC,EACA,QAAAC,EAAU,OACV,IAAAC,EACA,IAAAC,EACA,SAAUC,EACV,GAAGC,CACL,EAAIlB,EAAaK,EAAON,EAAeE,EAAgBC,EAAeC,CAAc,EAG9EgB,EACJtB,EAAA,cAAC,OACC,cAAae,EACb,QAASE,EACT,MAAOD,EACP,UAAWf,EACT,WACA,WACAS,IAAY,QAAU,iBACtBI,CACF,EACA,IAAKI,EACL,IAAKC,EACJ,GAAGE,EACJ,IAAKZ,EACP,EAIF,GAAII,GAAWD,EAAU,CACvB,MAAMW,EAAQvB,EAAM,SAAS,KAAKY,CAAQ,EAE1C,OAAIF,IAAY,OAEPV,EAAM,aAAauB,EAAO,CAC/B,UAAWtB,EAAWsB,EAAM,OAAO,UAAW,iBAAiB,EAC/D,MAAO,CACL,SAAU,WACV,QAAS,eACT,eAAgB,OAChB,MAAO,UACP,O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P,CACF,EAIGa,CACT,CAAC,EAEDf,EAAM,YAAc",
|
|
6
|
+
"names": ["React", "classNames", "imagePropDefs", "extractProps", "marginPropDefs", "widthPropDefs", "heightPropDefs", "Image", "props", "forwardedRef", "variant", "fit", "children", "asChild", "className", "radius", "style", "loading", "alt", "src", "_children", "imgProps", "imgElement", "child"]
|
|
7
|
+
}
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
declare const imagePropDefs: {
|
|
2
|
+
shadow: {
|
|
3
|
+
type: "enum";
|
|
4
|
+
className: string;
|
|
5
|
+
values: readonly ["1", "2", "3", "4", "5", "6"];
|
|
6
|
+
responsive: true;
|
|
7
|
+
};
|
|
8
|
+
radius: {
|
|
9
|
+
type: "enum";
|
|
10
|
+
values: readonly ["none", "small", "medium", "large", "full"];
|
|
11
|
+
default: undefined;
|
|
12
|
+
};
|
|
13
|
+
/**
|
|
14
|
+
* Sets the CSS **object-fit** property.
|
|
15
|
+
* Controls how the image should be resized to fit its container.
|
|
16
|
+
*
|
|
17
|
+
* @example
|
|
18
|
+
* fit="cover"
|
|
19
|
+
* fit="contain"
|
|
20
|
+
*
|
|
21
|
+
* @link
|
|
22
|
+
* https://developer.mozilla.org/en-US/docs/Web/CSS/object-fit
|
|
23
|
+
*/
|
|
24
|
+
fit: {
|
|
25
|
+
type: "enum";
|
|
26
|
+
className: string;
|
|
27
|
+
values: readonly ["cover", "contain", "fill", "scale-down", "none"];
|
|
28
|
+
default: "cover";
|
|
29
|
+
responsive: true;
|
|
30
|
+
};
|
|
31
|
+
/**
|
|
32
|
+
* Sets the visual variant of the image.
|
|
33
|
+
*
|
|
34
|
+
* @example
|
|
35
|
+
* variant="surface"
|
|
36
|
+
* variant="blur"
|
|
37
|
+
*/
|
|
38
|
+
variant: {
|
|
39
|
+
type: "enum";
|
|
40
|
+
className: string;
|
|
41
|
+
values: readonly ["surface", "blur"];
|
|
42
|
+
default: "surface";
|
|
43
|
+
};
|
|
44
|
+
asChild: {
|
|
45
|
+
type: "boolean";
|
|
46
|
+
};
|
|
47
|
+
};
|
|
48
|
+
export { imagePropDefs };
|
|
49
|
+
//# sourceMappingURL=image.props.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"image.props.d.ts","sourceRoot":"","sources":["../../../src/components/image.props.ts"],"names":[],"mappings":"AASA,QAAA,MAAM,aAAa;;;;;;;;;;;;IAEjB;;;;;;;;;;OAUG;;;;;;;;IAQH;;;;;;OAMG;;;;;;;;;;CAYJ,CAAC;AAEF,OAAO,EAAE,aAAa,EAAE,CAAC"}
|