@rubin-epo/epo-widget-lib 0.2.1 → 0.4.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.MD +21 -15
- package/dist/CameraFilter.cjs +1 -0
- package/dist/CameraFilter.d.ts +3 -0
- package/dist/CameraFilter.js +99 -0
- package/dist/ColorTool.cjs +1 -0
- package/dist/ColorTool.d.ts +3 -0
- package/dist/ColorTool.js +116 -0
- package/dist/FilterTool.cjs +1 -0
- package/dist/FilterTool.d.ts +3 -0
- package/dist/FilterTool.js +253 -0
- package/dist/SourceSelector.cjs +1 -0
- package/dist/SourceSelector.d.ts +3 -0
- package/dist/SourceSelector.js +97 -0
- package/dist/atomic/Blinker/Blinker.cjs +1 -0
- package/dist/atomic/Blinker/Blinker.d.ts +2 -2
- package/dist/atomic/Blinker/Blinker.js +68 -0
- package/dist/atomic/Blinker/Controls/Controls.cjs +1 -0
- package/dist/atomic/Blinker/Controls/Controls.js +58 -0
- package/dist/atomic/Blinker/Controls/styles.cjs +13 -0
- package/dist/atomic/Blinker/Controls/styles.d.ts +2 -1
- package/dist/atomic/Blinker/Controls/styles.js +17 -0
- package/dist/atomic/Blinker/Image/Image.cjs +1 -0
- package/dist/atomic/Blinker/Image/Image.d.ts +2 -2
- package/dist/atomic/Blinker/Image/Image.js +23 -0
- package/dist/atomic/Blinker/Image/styles.cjs +22 -0
- package/dist/atomic/Blinker/Image/styles.d.ts +4 -3
- package/dist/atomic/Blinker/Image/styles.js +26 -0
- package/dist/atomic/Blinker/Images/Images.cjs +1 -0
- package/dist/atomic/Blinker/Images/Images.js +37 -0
- package/dist/atomic/Blinker/Images/styles.cjs +15 -0
- package/dist/atomic/Blinker/Images/styles.d.ts +5 -4
- package/dist/atomic/Blinker/Images/styles.js +20 -0
- package/dist/atomic/Blinker/_mocks/index.d.ts +2 -0
- package/dist/atomic/Blinker/styles.cjs +26 -0
- package/dist/atomic/Blinker/styles.d.ts +7 -9
- package/dist/atomic/Blinker/styles.js +34 -0
- package/dist/atomic/ElapsedTime/ElapsedTime.cjs +1 -0
- package/dist/atomic/ElapsedTime/ElapsedTime.js +34 -0
- package/dist/atomic/ElapsedTime/styles.cjs +40 -0
- package/dist/atomic/ElapsedTime/styles.d.ts +7 -6
- package/dist/atomic/ElapsedTime/styles.js +49 -0
- package/dist/atomic/PlaybackControl/PlaybackControl.cjs +1 -0
- package/dist/atomic/PlaybackControl/PlaybackControl.d.ts +1 -1
- package/dist/atomic/PlaybackControl/PlaybackControl.js +17 -0
- package/dist/atomic/PlaybackControl/styles.cjs +39 -0
- package/dist/atomic/PlaybackControl/styles.d.ts +3 -2
- package/dist/atomic/PlaybackControl/styles.js +44 -0
- package/dist/hooks/useInterval.cjs +1 -0
- package/dist/hooks/useInterval.js +18 -0
- package/dist/lib/utils.cjs +1 -0
- package/dist/lib/utils.js +18 -0
- package/dist/lib/utils.test.d.ts +1 -0
- package/dist/localeStrings/en/epo-widget-lib.json +77 -0
- package/dist/localeStrings/es/epo-widget-lib.json +33 -0
- package/dist/styles/svg.cjs +8 -0
- package/dist/styles/svg.d.ts +2 -1
- package/dist/styles/svg.js +12 -0
- package/dist/widgets/CameraFilter/CondensedFilterRanges/CondensedFilterRanges.cjs +1 -0
- package/dist/widgets/CameraFilter/CondensedFilterRanges/CondensedFilterRanges.js +61 -0
- package/dist/widgets/CameraFilter/SpectrumDisplay/ColorLabels/ColorLabels.cjs +1 -0
- package/dist/widgets/CameraFilter/SpectrumDisplay/ColorLabels/ColorLabels.js +95 -0
- package/dist/widgets/CameraFilter/SpectrumDisplay/SpectrumDisplay.cjs +1 -0
- package/dist/widgets/CameraFilter/SpectrumDisplay/SpectrumDisplay.js +98 -0
- package/dist/widgets/CameraFilter/SpectrumDisplay/SpectrumLabels/SpectrumLabels.cjs +1 -0
- package/dist/widgets/CameraFilter/SpectrumDisplay/SpectrumLabels/SpectrumLabels.js +58 -0
- package/dist/widgets/CameraFilter/data.cjs +1 -0
- package/dist/widgets/CameraFilter/data.js +85 -0
- package/dist/widgets/CameraFilter/styles.cjs +64 -0
- package/dist/widgets/CameraFilter/styles.d.ts +19 -18
- package/dist/widgets/CameraFilter/styles.js +82 -0
- package/dist/widgets/ColorTool/ColorTool.d.ts +1 -2
- package/dist/widgets/ColorTool/FilterControls/FilterControls.cjs +1 -0
- package/dist/widgets/ColorTool/FilterControls/FilterControls.d.ts +1 -1
- package/dist/widgets/ColorTool/FilterControls/FilterControls.js +63 -0
- package/dist/widgets/ColorTool/FilterImage/FilterImage.cjs +1 -0
- package/dist/widgets/ColorTool/FilterImage/FilterImage.js +41 -0
- package/dist/widgets/ColorTool/ImageComposite/ImageComposite.cjs +1 -0
- package/dist/widgets/ColorTool/ImageComposite/ImageComposite.js +33 -0
- package/dist/widgets/ColorTool/styles.cjs +129 -0
- package/dist/widgets/ColorTool/styles.d.ts +21 -21
- package/dist/widgets/ColorTool/styles.js +149 -0
- package/dist/widgets/ColorTool/utilities.cjs +1 -0
- package/dist/widgets/ColorTool/utilities.js +38 -0
- package/dist/widgets/FilterTool/FilterTool.d.ts +3 -1
- package/dist/widgets/FilterTool/styles.cjs +36 -0
- package/dist/widgets/FilterTool/styles.d.ts +10 -15
- package/dist/widgets/FilterTool/styles.js +49 -0
- package/dist/widgets/SourceSelector/Message/Message.cjs +1 -0
- package/dist/widgets/SourceSelector/Message/Message.js +21 -0
- package/dist/widgets/SourceSelector/Message/styles.cjs +23 -0
- package/dist/widgets/SourceSelector/Message/styles.d.ts +5 -0
- package/dist/widgets/SourceSelector/Message/styles.js +28 -0
- package/dist/widgets/SourceSelector/Point/Point.cjs +1 -0
- package/dist/widgets/SourceSelector/Point/Point.js +45 -0
- package/dist/widgets/SourceSelector/Point/styles.cjs +11 -0
- package/dist/widgets/SourceSelector/Point/styles.d.ts +4 -3
- package/dist/widgets/SourceSelector/Point/styles.js +15 -0
- package/dist/widgets/SourceSelector/Points/Points.cjs +1 -0
- package/dist/widgets/SourceSelector/Points/Points.js +35 -0
- package/dist/widgets/SourceSelector/SourceSelector.d.ts +2 -2
- package/dist/widgets/SourceSelector/mocks/index.d.ts +7 -0
- package/dist/widgets/SourceSelector/styles.cjs +20 -0
- package/dist/widgets/SourceSelector/styles.d.ts +9 -7
- package/dist/widgets/SourceSelector/styles.js +30 -0
- package/dist/widgets/SourceSelector/utilities.cjs +1 -0
- package/dist/widgets/SourceSelector/utilities.js +7 -0
- package/dist/widgets/SourceSelector/utilities.test.d.ts +1 -0
- package/package.json +12 -11
- package/dist/assets/locales/index.d.ts +0 -115
- package/dist/epo-widget-lib.es.js +0 -3427
- package/dist/epo-widget-lib.umd.js +0 -459
- package/dist/index.d.ts +0 -6
- package/dist/types/astro.d.ts +0 -35
- package/dist/vite-env.d.ts +0 -1
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r=require("styled-components"),s=require("../../styles/svg.cjs"),a=require("../../atomic/Blinker/Blinker.cjs"),l=require("../../atomic/ElapsedTime/ElapsedTime.cjs"),i=e=>e&&e.__esModule?e:{default:e},t=i(r),n=t.default(s.Container)`
|
|
2
|
+
${({width:e,height:o})=>r.css`
|
|
3
|
+
aspect-ratio: ${e} / ${o};
|
|
4
|
+
max-width: ${e}px;
|
|
5
|
+
max-height: ${o}px;
|
|
6
|
+
`}
|
|
7
|
+
`,u=t.default.svg`
|
|
8
|
+
position: absolute;
|
|
9
|
+
top: 0;
|
|
10
|
+
left: 0;
|
|
11
|
+
cursor: ${({$isDisplayOnly:e})=>e?"default":"pointer"};
|
|
12
|
+
`,c=t.default(a.default)`
|
|
13
|
+
position: absolute;
|
|
14
|
+
width: 100%;
|
|
15
|
+
height: 100%;
|
|
16
|
+
`,d=t.default(l.default)`
|
|
17
|
+
position: absolute;
|
|
18
|
+
right: var(--PADDING_SMALL, 20px);
|
|
19
|
+
bottom: var(--PADDING_SMALL, 20px);
|
|
20
|
+
`;exports.BackgroundBlinker=c;exports.ElapsedDisplay=d;exports.SVG=u;exports.SourceSelectorContainer=n;
|
|
@@ -1,10 +1,12 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
export declare const SourceSelectorContainer: import("styled-components").
|
|
2
|
+
export declare const SourceSelectorContainer: import("styled-components").IStyledComponent<"web", import("styled-components/dist/types").Substitute<Omit<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>, "ref"> & {
|
|
3
|
+
ref?: ((instance: HTMLDivElement | null) => void) | import("react").RefObject<HTMLDivElement> | null | undefined;
|
|
4
|
+
}, {
|
|
3
5
|
width: number;
|
|
4
6
|
height: number;
|
|
5
|
-
}
|
|
6
|
-
export declare const SVG: import("styled-components").
|
|
7
|
-
isDisplayOnly: boolean;
|
|
8
|
-
}
|
|
9
|
-
export declare const BackgroundBlinker: import("styled-components").
|
|
10
|
-
export declare const ElapsedDisplay: import("styled-components").
|
|
7
|
+
}>>;
|
|
8
|
+
export declare const SVG: import("styled-components").IStyledComponent<"web", import("styled-components/dist/types").Substitute<import("react").SVGProps<SVGSVGElement>, {
|
|
9
|
+
$isDisplayOnly: boolean;
|
|
10
|
+
}>>;
|
|
11
|
+
export declare const BackgroundBlinker: import("styled-components").IStyledComponent<"web", Omit<import("../../atomic/Blinker/Blinker").BlinkerProps, never>>;
|
|
12
|
+
export declare const ElapsedDisplay: import("styled-components").IStyledComponent<"web", Omit<import("../../atomic/ElapsedTime/ElapsedTime").TimeStepProps, never>>;
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import t, { css as i } from "styled-components";
|
|
2
|
+
import { Container as e } from "../../styles/svg.js";
|
|
3
|
+
import s from "../../atomic/Blinker/Blinker.js";
|
|
4
|
+
import p from "../../atomic/ElapsedTime/ElapsedTime.js";
|
|
5
|
+
const c = t(e)`
|
|
6
|
+
${({ width: o, height: r }) => i`
|
|
7
|
+
aspect-ratio: ${o} / ${r};
|
|
8
|
+
max-width: ${o}px;
|
|
9
|
+
max-height: ${r}px;
|
|
10
|
+
`}
|
|
11
|
+
`, u = t.svg`
|
|
12
|
+
position: absolute;
|
|
13
|
+
top: 0;
|
|
14
|
+
left: 0;
|
|
15
|
+
cursor: ${({ $isDisplayOnly: o }) => o ? "default" : "pointer"};
|
|
16
|
+
`, x = t(s)`
|
|
17
|
+
position: absolute;
|
|
18
|
+
width: 100%;
|
|
19
|
+
height: 100%;
|
|
20
|
+
`, d = t(p)`
|
|
21
|
+
position: absolute;
|
|
22
|
+
right: var(--PADDING_SMALL, 20px);
|
|
23
|
+
bottom: var(--PADDING_SMALL, 20px);
|
|
24
|
+
`;
|
|
25
|
+
export {
|
|
26
|
+
x as BackgroundBlinker,
|
|
27
|
+
d as ElapsedDisplay,
|
|
28
|
+
u as SVG,
|
|
29
|
+
c as SourceSelectorContainer
|
|
30
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=(t,n)=>{const[r,a]=t,[e,c]=n;return i=>i/(a-r)*(c-e)+e};exports.getLinearScale=o;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@rubin-epo/epo-widget-lib",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.4.1",
|
|
4
4
|
"description": "Rubin Observatory Education & Public Outreach team React scientific and educational widgets.",
|
|
5
5
|
"author": "Rubin EPO",
|
|
6
6
|
"license": "MIT",
|
|
@@ -17,14 +17,14 @@
|
|
|
17
17
|
"README.md",
|
|
18
18
|
"dist"
|
|
19
19
|
],
|
|
20
|
-
"
|
|
21
|
-
"module": "./dist/epo-widget-lib.es.js",
|
|
22
|
-
"types": "./dist/index.d.ts",
|
|
20
|
+
"sideEffects": false,
|
|
23
21
|
"exports": {
|
|
24
|
-
"
|
|
25
|
-
"import": "./dist
|
|
26
|
-
"require": "./dist
|
|
27
|
-
|
|
22
|
+
"./*": {
|
|
23
|
+
"import": "./dist/*.js",
|
|
24
|
+
"require": "./dist/*.cjs",
|
|
25
|
+
"types": "./dist/*.d.ts"
|
|
26
|
+
},
|
|
27
|
+
"./localeStrings": "./dist/localeStrings"
|
|
28
28
|
},
|
|
29
29
|
"publishConfig": {
|
|
30
30
|
"access": "public",
|
|
@@ -38,8 +38,9 @@
|
|
|
38
38
|
"react-i18next": "^12.2.0"
|
|
39
39
|
},
|
|
40
40
|
"dependencies": {
|
|
41
|
-
"@rubin-epo/epo-react-lib": "^
|
|
42
|
-
"styled-components": "^
|
|
43
|
-
"use-resize-observer": "^9.1.0"
|
|
41
|
+
"@rubin-epo/epo-react-lib": "^2.0.0-beta.6",
|
|
42
|
+
"styled-components": "^6.0.1",
|
|
43
|
+
"use-resize-observer": "^9.1.0",
|
|
44
|
+
"lodash": "^4.17.21"
|
|
44
45
|
}
|
|
45
46
|
}
|
|
@@ -1,115 +0,0 @@
|
|
|
1
|
-
declare const _default: {
|
|
2
|
-
en: {
|
|
3
|
-
translation: {
|
|
4
|
-
blinker: {
|
|
5
|
-
controls: {
|
|
6
|
-
rewind: string;
|
|
7
|
-
forward: string;
|
|
8
|
-
play: string;
|
|
9
|
-
pause: string;
|
|
10
|
-
};
|
|
11
|
-
};
|
|
12
|
-
elapsed_time: {
|
|
13
|
-
title: string;
|
|
14
|
-
step: {
|
|
15
|
-
day_one: string;
|
|
16
|
-
day_other: string;
|
|
17
|
-
hour_one: string;
|
|
18
|
-
hour_other: string;
|
|
19
|
-
minute_one: string;
|
|
20
|
-
minute_other: string;
|
|
21
|
-
second_one: string;
|
|
22
|
-
second_other: string;
|
|
23
|
-
year_one: string;
|
|
24
|
-
year_other: string;
|
|
25
|
-
};
|
|
26
|
-
};
|
|
27
|
-
filterTool: {
|
|
28
|
-
title: string;
|
|
29
|
-
filter: string;
|
|
30
|
-
whiteLight: string;
|
|
31
|
-
prism: string;
|
|
32
|
-
selectLabel: string;
|
|
33
|
-
colors: {
|
|
34
|
-
violet: string;
|
|
35
|
-
blue: string;
|
|
36
|
-
green: string;
|
|
37
|
-
yellow: string;
|
|
38
|
-
orange: string;
|
|
39
|
-
red: string;
|
|
40
|
-
none: string;
|
|
41
|
-
};
|
|
42
|
-
};
|
|
43
|
-
colorTool: {
|
|
44
|
-
labels: {
|
|
45
|
-
object_type: string;
|
|
46
|
-
object: string;
|
|
47
|
-
object_selected: string;
|
|
48
|
-
filter: string;
|
|
49
|
-
color: string;
|
|
50
|
-
color_intensity: string;
|
|
51
|
-
};
|
|
52
|
-
actions: {
|
|
53
|
-
select_an_object: string;
|
|
54
|
-
select_filter: string;
|
|
55
|
-
reset: string;
|
|
56
|
-
};
|
|
57
|
-
};
|
|
58
|
-
source_selector: {
|
|
59
|
-
messages: {
|
|
60
|
-
success: string;
|
|
61
|
-
failure: string;
|
|
62
|
-
};
|
|
63
|
-
};
|
|
64
|
-
camera_filter: {
|
|
65
|
-
title: string;
|
|
66
|
-
labels: {
|
|
67
|
-
select: string;
|
|
68
|
-
option: string;
|
|
69
|
-
option_none: string;
|
|
70
|
-
captured_range: string;
|
|
71
|
-
captured_range_no_filter: string;
|
|
72
|
-
ultraviolet: string;
|
|
73
|
-
visible: string;
|
|
74
|
-
infrared: string;
|
|
75
|
-
};
|
|
76
|
-
};
|
|
77
|
-
};
|
|
78
|
-
};
|
|
79
|
-
es: {
|
|
80
|
-
translation: {
|
|
81
|
-
elapsed_time: {
|
|
82
|
-
title: string;
|
|
83
|
-
step: {
|
|
84
|
-
day_one: string;
|
|
85
|
-
day_other: string;
|
|
86
|
-
hour_one: string;
|
|
87
|
-
hour_other: string;
|
|
88
|
-
minute_one: string;
|
|
89
|
-
minute_other: string;
|
|
90
|
-
second_one: string;
|
|
91
|
-
second_other: string;
|
|
92
|
-
year_one: string;
|
|
93
|
-
year_other: string;
|
|
94
|
-
};
|
|
95
|
-
};
|
|
96
|
-
filterTool: {
|
|
97
|
-
title: string;
|
|
98
|
-
filter: string;
|
|
99
|
-
whiteLight: string;
|
|
100
|
-
prism: string;
|
|
101
|
-
selectLabel: string;
|
|
102
|
-
colors: {
|
|
103
|
-
violet: string;
|
|
104
|
-
blue: string;
|
|
105
|
-
green: string;
|
|
106
|
-
yellow: string;
|
|
107
|
-
orange: string;
|
|
108
|
-
red: string;
|
|
109
|
-
none: string;
|
|
110
|
-
};
|
|
111
|
-
};
|
|
112
|
-
};
|
|
113
|
-
};
|
|
114
|
-
};
|
|
115
|
-
export default _default;
|