@jamsrui/clipboard 0.0.5 → 0.0.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/clipboard-button.mjs +1 -1
- package/dist/clipboard-config.d.mts +3 -2
- package/dist/clipboard.d.mts +3 -2
- package/dist/clipboard.mjs +1 -1
- package/dist/index.d.mts +2 -1
- package/dist/styles.d.mts +13 -12
- package/dist/use-clipboard.d.mts +1 -1
- package/package.json +5 -5
|
@@ -1 +1 @@
|
|
|
1
|
-
import{useRenderElement as
|
|
1
|
+
import{jsx as t}from"react/jsx-runtime";import{useRenderElement as u}from"@jamsrui/hooks";import{CheckIcon as d,CopyIcon as m}from"@jamsrui/icons";import{useClipboardContext as c}from"./clipboard-context";const b=r=>{const{getButtonProps:e,hideCopyButton:n,isCopied:p,getIconProps:o}=c(),s=p?t(d,{...o({})}):t(m,{...o({})}),i=u("button",{props:[e(r),{children:s}]});return n?null:i};export{b as ClipboardButton};
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import { Clipboard } from './clipboard.mjs';
|
|
2
|
-
import * as
|
|
2
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
3
3
|
import { GlobalConfigProps } from '@jamsrui/core';
|
|
4
4
|
import './use-clipboard.mjs';
|
|
5
|
+
import 'react';
|
|
5
6
|
import './use-copy-to-clipboard.mjs';
|
|
6
7
|
import '@jamsrui/utils';
|
|
7
8
|
import './clipboard-button.mjs';
|
|
@@ -11,7 +12,7 @@ import 'tailwind-variants';
|
|
|
11
12
|
declare const useClipboardConfig: () => ClipboardConfig.Props;
|
|
12
13
|
declare const ClipboardConfig: (props: ClipboardConfig.Props & {
|
|
13
14
|
merge?: boolean;
|
|
14
|
-
}) =>
|
|
15
|
+
}) => react_jsx_runtime.JSX.Element;
|
|
15
16
|
declare namespace ClipboardConfig {
|
|
16
17
|
interface Props extends Clipboard.Props, GlobalConfigProps<Clipboard.Props> {
|
|
17
18
|
}
|
package/dist/clipboard.d.mts
CHANGED
|
@@ -1,12 +1,13 @@
|
|
|
1
|
-
import * as
|
|
1
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
2
|
import { useClipboard } from './use-clipboard.mjs';
|
|
3
|
+
import 'react';
|
|
3
4
|
import './use-copy-to-clipboard.mjs';
|
|
4
5
|
import '@jamsrui/utils';
|
|
5
6
|
import './clipboard-button.mjs';
|
|
6
7
|
import './styles.mjs';
|
|
7
8
|
import 'tailwind-variants';
|
|
8
9
|
|
|
9
|
-
declare const Clipboard: (props: Clipboard.Props) =>
|
|
10
|
+
declare const Clipboard: (props: Clipboard.Props) => react_jsx_runtime.JSX.Element;
|
|
10
11
|
declare namespace Clipboard {
|
|
11
12
|
interface Props extends useClipboard.Props {
|
|
12
13
|
}
|
package/dist/clipboard.mjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{useRenderElement as
|
|
1
|
+
import{Fragment as f,jsx as t,jsxs as g}from"react/jsx-runtime";import{useRenderElement as l}from"@jamsrui/hooks";import{mergeConfigProps as m}from"@jamsrui/utils";import{ClipboardButton as c}from"./clipboard-button";import{useClipboardConfig as C}from"./clipboard-config";import{ClipboardContext as a}from"./clipboard-context";import{useClipboard as b}from"./use-clipboard";const v=o=>{const r=C(),p=m(r,r,o),e=b(p),{getRootProps:n}=e,{children:i}=o,s=g(f,{children:[i,t(c,{})]}),d=l("label",{props:[n(),{children:s}]});return t(a,{value:e,children:d})};export{v as Clipboard};
|
package/dist/index.d.mts
CHANGED
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
export { Clipboard } from './clipboard.mjs';
|
|
2
2
|
export { ClipboardConfig, useClipboardConfig } from './clipboard-config.mjs';
|
|
3
|
-
import 'react';
|
|
3
|
+
import 'react/jsx-runtime';
|
|
4
4
|
import './use-clipboard.mjs';
|
|
5
|
+
import 'react';
|
|
5
6
|
import './use-copy-to-clipboard.mjs';
|
|
6
7
|
import '@jamsrui/utils';
|
|
7
8
|
import './clipboard-button.mjs';
|
package/dist/styles.d.mts
CHANGED
|
@@ -1,21 +1,22 @@
|
|
|
1
1
|
import * as tailwind_variants from 'tailwind-variants';
|
|
2
|
+
import * as _jamsrui_utils from '@jamsrui/utils';
|
|
2
3
|
import { VariantProps } from '@jamsrui/utils';
|
|
3
4
|
|
|
4
5
|
declare const test = "";
|
|
5
6
|
declare const copyToClipboardVariants: tailwind_variants.TVReturnType<{
|
|
6
7
|
[key: string]: {
|
|
7
|
-
[key: string]:
|
|
8
|
-
button?:
|
|
9
|
-
root?:
|
|
10
|
-
icon?:
|
|
8
|
+
[key: string]: _jamsrui_utils.ClassValue | {
|
|
9
|
+
button?: _jamsrui_utils.ClassValue;
|
|
10
|
+
root?: _jamsrui_utils.ClassValue;
|
|
11
|
+
icon?: _jamsrui_utils.ClassValue;
|
|
11
12
|
};
|
|
12
13
|
};
|
|
13
14
|
} | {
|
|
14
15
|
[x: string]: {
|
|
15
|
-
[x: string]:
|
|
16
|
-
button?:
|
|
17
|
-
root?:
|
|
18
|
-
icon?:
|
|
16
|
+
[x: string]: _jamsrui_utils.ClassValue | {
|
|
17
|
+
button?: _jamsrui_utils.ClassValue;
|
|
18
|
+
root?: _jamsrui_utils.ClassValue;
|
|
19
|
+
icon?: _jamsrui_utils.ClassValue;
|
|
19
20
|
};
|
|
20
21
|
};
|
|
21
22
|
} | {}, {
|
|
@@ -24,10 +25,10 @@ declare const copyToClipboardVariants: tailwind_variants.TVReturnType<{
|
|
|
24
25
|
icon: string;
|
|
25
26
|
}, undefined, {
|
|
26
27
|
[key: string]: {
|
|
27
|
-
[key: string]:
|
|
28
|
-
button?:
|
|
29
|
-
root?:
|
|
30
|
-
icon?:
|
|
28
|
+
[key: string]: _jamsrui_utils.ClassValue | {
|
|
29
|
+
button?: _jamsrui_utils.ClassValue;
|
|
30
|
+
root?: _jamsrui_utils.ClassValue;
|
|
31
|
+
icon?: _jamsrui_utils.ClassValue;
|
|
31
32
|
};
|
|
32
33
|
};
|
|
33
34
|
} | {}, {
|
package/dist/use-clipboard.d.mts
CHANGED
|
@@ -17,6 +17,7 @@ declare const useClipboard: (props: useClipboard.Props) => {
|
|
|
17
17
|
title?: string | undefined | undefined;
|
|
18
18
|
ref?: react.Ref<HTMLLabelElement> | undefined;
|
|
19
19
|
key?: react.Key | null | undefined;
|
|
20
|
+
htmlFor?: string | undefined | undefined;
|
|
20
21
|
suppressContentEditableWarning?: boolean | undefined | undefined;
|
|
21
22
|
suppressHydrationWarning?: boolean | undefined | undefined;
|
|
22
23
|
accessKey?: string | undefined | undefined;
|
|
@@ -291,7 +292,6 @@ declare const useClipboard: (props: useClipboard.Props) => {
|
|
|
291
292
|
onTransitionRunCapture?: react.TransitionEventHandler<HTMLLabelElement> | undefined;
|
|
292
293
|
onTransitionStart?: react.TransitionEventHandler<HTMLLabelElement> | undefined;
|
|
293
294
|
onTransitionStartCapture?: react.TransitionEventHandler<HTMLLabelElement> | undefined;
|
|
294
|
-
htmlFor?: string | undefined | undefined;
|
|
295
295
|
render?: React.ReactElement;
|
|
296
296
|
};
|
|
297
297
|
getButtonProps: PropGetter<ClipboardButton.Props>;
|
package/package.json
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@jamsrui/clipboard",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.7",
|
|
4
4
|
"peerDependencies": {
|
|
5
5
|
"react": ">=19"
|
|
6
6
|
},
|
|
7
7
|
"dependencies": {
|
|
8
|
-
"@jamsrui/hooks": "^0.0.
|
|
9
|
-
"@jamsrui/core": "^0.0.
|
|
10
|
-
"@jamsrui/
|
|
11
|
-
"@jamsrui/
|
|
8
|
+
"@jamsrui/hooks": "^0.0.7",
|
|
9
|
+
"@jamsrui/core": "^0.0.7",
|
|
10
|
+
"@jamsrui/icons": "^0.0.7",
|
|
11
|
+
"@jamsrui/utils": "^0.0.7"
|
|
12
12
|
},
|
|
13
13
|
"exports": {
|
|
14
14
|
".": {
|