@weing-dev/ui-kit-primitive 0.1.1 → 0.2.0
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 +9 -0
- package/dist/components/Accordion/Accordion.d.ts +3 -3
- package/dist/components/Avatar/Avatar.d.ts +2 -2
- package/dist/components/Badge/Badge.d.ts +2 -2
- package/dist/components/Breadcrumb/Breadcrumb.d.ts +5 -5
- package/dist/components/Button/Button.d.ts +4 -4
- package/dist/components/Button/button.augment.d.ts +17 -0
- package/dist/components/Calendar/Calendar.d.ts +6 -6
- package/dist/components/Cascader/Cascader.d.ts +4 -4
- package/dist/components/Chips/Chips.d.ts +2 -2
- package/dist/components/Comment/Comment.d.ts +2 -2
- package/dist/components/Editor/Editor.context.d.ts +2 -0
- package/dist/components/Editor/Editor.d.ts +17 -1
- package/dist/components/Editor/constants/editor.constants.d.ts +73 -24
- package/dist/components/Form/CheckBox/CheckBox.d.ts +4 -4
- package/dist/components/Form/Dropdown/Dropdown.d.ts +4 -4
- package/dist/components/Form/OTPInput/OTPInput.d.ts +2 -2
- package/dist/components/Form/Radio/Radio.d.ts +4 -4
- package/dist/components/Form/Switch/Switch.d.ts +3 -3
- package/dist/components/Form/TextArea/TextArea.d.ts +6 -6
- package/dist/components/Form/TextInput/TextInput.d.ts +5 -5
- package/dist/components/GlobalStyle/GlobalStyle.d.ts +2 -0
- package/dist/components/HelperText/HelperText.d.ts +3 -2
- package/dist/components/Icon/Icon.constant.d.ts +6 -0
- package/dist/components/Icon/Icon.d.ts +12 -9
- package/dist/components/Icon/context/icon.context.d.ts +5 -0
- package/dist/components/Icon/context/icon.provider.d.ts +8 -0
- package/dist/components/Icon/context/icon.store.d.ts +16 -0
- package/dist/components/Icon/context/index.d.ts +3 -0
- package/dist/components/Icon/icon.augment.d.ts +17 -0
- package/dist/components/Icons/BackButton.d.ts +3 -0
- package/dist/components/Icons/FullScreen.d.ts +3 -0
- package/dist/components/Icons/FullScreenClose.d.ts +3 -0
- package/dist/components/Icons/Pause.d.ts +3 -0
- package/dist/components/Icons/Play.d.ts +3 -0
- package/dist/components/Icons/Share.d.ts +3 -0
- package/dist/components/Icons/VolumeOff.d.ts +3 -0
- package/dist/components/Icons/VolumeUp.d.ts +3 -0
- package/dist/components/Icons/index.d.ts +8 -0
- package/dist/components/LNB/LNB.d.ts +4 -4
- package/dist/components/Label/Label.d.ts +2 -2
- package/dist/components/List/List.d.ts +3 -3
- package/dist/components/Pagination/Pagination.d.ts +5 -5
- package/dist/components/Tab/Tab.d.ts +5 -5
- package/dist/components/Table/Table.d.ts +6 -6
- package/dist/components/TimeInput/TimeInput.d.ts +8 -8
- package/dist/components/VideoPlayer/VideoPlayer.d.ts +118 -0
- package/dist/components/VideoPlayer/components/Error/Error.d.ts +18 -0
- package/dist/components/VideoPlayer/components/Error/index.d.ts +1 -0
- package/dist/components/VideoPlayer/components/Frame/Frame.d.ts +34 -0
- package/dist/components/VideoPlayer/components/Frame/index.d.ts +2 -0
- package/dist/components/VideoPlayer/components/Loading/Loading.d.ts +12 -0
- package/dist/components/VideoPlayer/components/Loading/index.d.ts +1 -0
- package/dist/components/VideoPlayer/components/VideoOverlay/VideoOverlay.d.ts +37 -0
- package/dist/components/VideoPlayer/components/VideoOverlay/index.d.ts +2 -0
- package/dist/components/VideoPlayer/components/Widgets/Button/Button.d.ts +11 -0
- package/dist/components/VideoPlayer/components/Widgets/Button/index.d.ts +2 -0
- package/dist/components/VideoPlayer/components/Widgets/ProgressBar/ProgressBar.d.ts +18 -0
- package/dist/components/VideoPlayer/components/Widgets/ProgressBar/index.d.ts +2 -0
- package/dist/components/VideoPlayer/components/Widgets/SpeedControl/SpeedControl.d.ts +22 -0
- package/dist/components/VideoPlayer/components/Widgets/SpeedControl/index.d.ts +1 -0
- package/dist/components/VideoPlayer/components/Widgets/Time/Time.d.ts +15 -0
- package/dist/components/VideoPlayer/components/Widgets/Time/index.d.ts +2 -0
- package/dist/components/VideoPlayer/components/Widgets/VolumeControl/VolumeControl.d.ts +34 -0
- package/dist/components/VideoPlayer/components/Widgets/VolumeControl/index.d.ts +2 -0
- package/dist/components/VideoPlayer/components/Widgets/index.d.ts +30 -0
- package/dist/components/VideoPlayer/components/index.d.ts +6 -0
- package/dist/components/VideoPlayer/context/index.d.ts +3 -0
- package/dist/components/VideoPlayer/context/videoPlayer.context.d.ts +18 -0
- package/dist/components/VideoPlayer/context/videoPlayer.provider.d.ts +8 -0
- package/dist/components/VideoPlayer/context/videoPlayer.store.d.ts +45 -0
- package/dist/components/VideoPlayer/index.d.ts +4 -0
- package/dist/components/VideoPlayer/videoPlayer.constants.d.ts +48 -0
- package/dist/entry/augmentations.d.ts +4 -0
- package/dist/entry/components.d.ts +89 -0
- package/dist/entry/types.d.ts +36 -0
- package/dist/{index-BL3MWQXq.js → index-CsNmTnCb.js} +29 -38
- package/dist/index.css +2 -2
- package/dist/index.d.ts +3 -47
- package/dist/index.js +14271 -12914
- package/dist/index.umd.cjs +43 -15
- package/dist/static/icon/back_button.svg +8 -0
- package/dist/static/icon/full_screen.svg +3 -0
- package/dist/static/icon/full_screen_close.svg +1 -0
- package/dist/static/icon/pause.svg +1 -0
- package/dist/static/icon/play.svg +3 -0
- package/dist/static/icon/share.svg +1 -0
- package/dist/static/icon/volume_off.svg +1 -0
- package/dist/static/icon/volume_up.svg +1 -0
- package/dist/utils/common.utill.d.ts +1 -1
- package/package.json +20 -19
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { IconName } from '../../../../Icon/Icon';
|
|
3
|
+
type VolumeControlAsProps = {
|
|
4
|
+
defaultClassName: string;
|
|
5
|
+
volume: number;
|
|
6
|
+
isMuted: boolean;
|
|
7
|
+
ariaLabel: string;
|
|
8
|
+
onMuteToggle: () => void;
|
|
9
|
+
onVolumeChange: (volume: number) => void;
|
|
10
|
+
volumeOnIcon: IconName;
|
|
11
|
+
volumeOffIcon: IconName;
|
|
12
|
+
sliderVisible: boolean;
|
|
13
|
+
sliderValue: number;
|
|
14
|
+
onSliderFocus: (focused: boolean) => void;
|
|
15
|
+
onMouseEnter: () => void;
|
|
16
|
+
onMouseLeave: () => void;
|
|
17
|
+
onPointerDown: (event: React.PointerEvent<Element>) => void;
|
|
18
|
+
trackRef: React.RefObject<HTMLDivElement | null>;
|
|
19
|
+
};
|
|
20
|
+
export type VolumeControlProps = {
|
|
21
|
+
className?: string;
|
|
22
|
+
onInteractionChange?: (isActive: boolean) => void;
|
|
23
|
+
icons?: {
|
|
24
|
+
volumeOn?: IconName;
|
|
25
|
+
volumeOff?: IconName;
|
|
26
|
+
};
|
|
27
|
+
aria?: {
|
|
28
|
+
mute?: string;
|
|
29
|
+
unmute?: string;
|
|
30
|
+
};
|
|
31
|
+
as?: (props: VolumeControlAsProps) => React.ReactNode;
|
|
32
|
+
};
|
|
33
|
+
declare const VolumeControl: (props: VolumeControlProps) => import("react/jsx-runtime").JSX.Element;
|
|
34
|
+
export default VolumeControl;
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
export declare const Widgets: {
|
|
2
|
+
Button: (props: import('./Button').ButtonProps) => import("react/jsx-runtime").JSX.Element;
|
|
3
|
+
ProgressBar: (props: import('./ProgressBar').ProgressBarProps) => import("react/jsx-runtime").JSX.Element;
|
|
4
|
+
VolumeControl: (props: import('./VolumeControl').VolumeControlProps) => import("react/jsx-runtime").JSX.Element;
|
|
5
|
+
SpeedControl: (props: {
|
|
6
|
+
className?: string;
|
|
7
|
+
variant?: "menu" | "cycle";
|
|
8
|
+
speedOptions?: number[];
|
|
9
|
+
ariaLabel?: string;
|
|
10
|
+
as?: (props: {
|
|
11
|
+
defaultClassName: string;
|
|
12
|
+
playbackRate: number;
|
|
13
|
+
speedOptions: readonly number[];
|
|
14
|
+
variant: "menu" | "cycle";
|
|
15
|
+
isOpen: boolean;
|
|
16
|
+
ariaLabel: string;
|
|
17
|
+
onButtonClick: () => void;
|
|
18
|
+
onSpeedSelect: (speed: number) => void;
|
|
19
|
+
onMouseEnter: () => void;
|
|
20
|
+
onMouseLeave: () => void;
|
|
21
|
+
}) => React.ReactNode;
|
|
22
|
+
}) => import("react/jsx-runtime").JSX.Element;
|
|
23
|
+
Time: (props: import('./Time').TimeProps) => import("react/jsx-runtime").JSX.Element;
|
|
24
|
+
};
|
|
25
|
+
export { default as Button } from './Button';
|
|
26
|
+
export type { ButtonProps } from './Button';
|
|
27
|
+
export { default as ProgressBar } from './ProgressBar';
|
|
28
|
+
export { default as VolumeControl } from './VolumeControl';
|
|
29
|
+
export { default as SpeedControl } from './SpeedControl';
|
|
30
|
+
export { default as Time } from './Time';
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
export { default as VideoOverlay } from './VideoOverlay';
|
|
2
|
+
export { default as Loading } from './Loading';
|
|
3
|
+
export { default as Error } from './Error';
|
|
4
|
+
export { default as Frame } from './Frame';
|
|
5
|
+
export { Widgets } from './Widgets';
|
|
6
|
+
export type { ButtonProps } from './Widgets';
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
export { useVideoPlayerStore, useVideoPlayerShallow, VideoPlayerStoreContext, VideoPlayerImageContext, useVideoPlayerImage, DefaultImage, type VideoPlayerStoreApi, type VideoPlayerImageComponent, type VideoPlayerImageProps, } from './videoPlayer.context';
|
|
2
|
+
export { default as VideoPlayerProvider } from './videoPlayer.provider';
|
|
3
|
+
export { createVideoPlayerStore, resolveVideoPlayerStoreConfig, type VideoPlayerStore, type VideoPlayerState, type VideoPlayerActions, type VideoPlayerStoreConfig, } from './videoPlayer.store';
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { createVideoPlayerStore, VideoPlayerStore } from './videoPlayer.store';
|
|
3
|
+
export type VideoPlayerStoreApi = ReturnType<typeof createVideoPlayerStore>;
|
|
4
|
+
export declare const VideoPlayerStoreContext: React.Context<import('zustand').UseBoundStore<import('zustand').StoreApi<VideoPlayerStore>> | undefined>;
|
|
5
|
+
export type VideoPlayerImageProps = {
|
|
6
|
+
src: string;
|
|
7
|
+
alt: string;
|
|
8
|
+
width?: number;
|
|
9
|
+
height?: number;
|
|
10
|
+
className?: string;
|
|
11
|
+
};
|
|
12
|
+
export type VideoPlayerImageComponent = React.ComponentType<VideoPlayerImageProps>;
|
|
13
|
+
export declare const DefaultImage: (props: VideoPlayerImageProps) => import("react/jsx-runtime").JSX.Element;
|
|
14
|
+
export declare const VideoPlayerImageContext: React.Context<VideoPlayerImageComponent>;
|
|
15
|
+
export declare const useVideoPlayerImage: () => VideoPlayerImageComponent;
|
|
16
|
+
export declare const useVideoPlayerStore: <R>(selector: (store: VideoPlayerStore) => R) => R;
|
|
17
|
+
export declare function useVideoPlayerShallow<R>(selector: (store: VideoPlayerStore) => R): R;
|
|
18
|
+
export declare function useVideoPlayerShallow<K extends keyof VideoPlayerStore>(keys: readonly K[]): Pick<VideoPlayerStore, K>;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { VideoPlayerStoreConfig } from './videoPlayer.store';
|
|
3
|
+
type VideoPlayerProviderProps = {
|
|
4
|
+
children: React.ReactNode;
|
|
5
|
+
storeConfig?: Partial<VideoPlayerStoreConfig>;
|
|
6
|
+
};
|
|
7
|
+
declare const VideoPlayerProvider: (props: VideoPlayerProviderProps) => import("react/jsx-runtime").JSX.Element;
|
|
8
|
+
export default VideoPlayerProvider;
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
import { default as videojs } from 'video.js';
|
|
2
|
+
type VideoJsPlayer = ReturnType<typeof videojs>;
|
|
3
|
+
export type VideoPlayerStoreConfig = {
|
|
4
|
+
volumePersist: boolean;
|
|
5
|
+
volumeStorageKey: string;
|
|
6
|
+
volumeFallback: number;
|
|
7
|
+
playbackRateDefault: number;
|
|
8
|
+
};
|
|
9
|
+
export type VideoPlayerState = {
|
|
10
|
+
isLoading: boolean;
|
|
11
|
+
hasError: boolean;
|
|
12
|
+
isPlaying: boolean;
|
|
13
|
+
currentTime: number;
|
|
14
|
+
duration: number;
|
|
15
|
+
buffered: number;
|
|
16
|
+
volume: number;
|
|
17
|
+
playbackRate: number;
|
|
18
|
+
isFullscreen: boolean;
|
|
19
|
+
isMuted: boolean;
|
|
20
|
+
previousVolume: number;
|
|
21
|
+
player: VideoJsPlayer | null;
|
|
22
|
+
};
|
|
23
|
+
export type VideoPlayerActions = {
|
|
24
|
+
setPlayer: (player: VideoJsPlayer | null) => void;
|
|
25
|
+
setLoading: (isLoading: boolean) => void;
|
|
26
|
+
setError: (hasError: boolean) => void;
|
|
27
|
+
setPlaying: (isPlaying: boolean) => void;
|
|
28
|
+
setCurrentTime: (currentTime: number) => void;
|
|
29
|
+
setDuration: (duration: number) => void;
|
|
30
|
+
setBuffered: (buffered: number) => void;
|
|
31
|
+
setVolume: (volume: number) => void;
|
|
32
|
+
setPlaybackRate: (playbackRate: number) => void;
|
|
33
|
+
setFullscreen: (isFullscreen: boolean) => void;
|
|
34
|
+
setMuted: (isMuted: boolean) => void;
|
|
35
|
+
handlePlayPause: () => void;
|
|
36
|
+
handleSeek: (time: number) => void;
|
|
37
|
+
handleVolumeChange: (volume: number) => void;
|
|
38
|
+
handleSpeedChange: (speed: number) => void;
|
|
39
|
+
handleFullscreenToggle: () => void;
|
|
40
|
+
handleMuteToggle: () => void;
|
|
41
|
+
};
|
|
42
|
+
export type VideoPlayerStore = VideoPlayerState & VideoPlayerActions;
|
|
43
|
+
export declare const resolveVideoPlayerStoreConfig: (config?: Partial<VideoPlayerStoreConfig>) => VideoPlayerStoreConfig;
|
|
44
|
+
export declare const createVideoPlayerStore: (config?: Partial<VideoPlayerStoreConfig>) => import('zustand').UseBoundStore<import('zustand').StoreApi<VideoPlayerStore>>;
|
|
45
|
+
export {};
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
export { default as VideoPlayer } from './VideoPlayer';
|
|
2
|
+
export type { VideoPlayerProps, VideoPlayerRootProps, VideoPlayerControls, VideoPlayerTexts, VideoPlayerAria, VideoPlayerIcons, VideoPlayerEvents, } from './VideoPlayer';
|
|
3
|
+
export { useVideoPlayerStore, useVideoPlayerShallow, VideoPlayerStoreContext, VideoPlayerImageContext, useVideoPlayerImage, DefaultImage, VideoPlayerProvider, createVideoPlayerStore, resolveVideoPlayerStoreConfig, type VideoPlayerStoreApi, type VideoPlayerImageComponent, type VideoPlayerImageProps, type VideoPlayerStore, type VideoPlayerState, type VideoPlayerActions, type VideoPlayerStoreConfig, } from './context';
|
|
4
|
+
export { VIDEO_PLAYER_DEFAULTS } from './videoPlayer.constants';
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
export declare const VIDEO_PLAYER_DEFAULTS: {
|
|
2
|
+
readonly layout: {
|
|
3
|
+
readonly width: "100%";
|
|
4
|
+
readonly height: "400px";
|
|
5
|
+
readonly maxWidth: "1200px";
|
|
6
|
+
};
|
|
7
|
+
readonly overlay: {
|
|
8
|
+
readonly autoHide: true;
|
|
9
|
+
readonly autoHideDelayMs: 1000;
|
|
10
|
+
};
|
|
11
|
+
readonly volume: {
|
|
12
|
+
readonly persist: true;
|
|
13
|
+
readonly storageKey: "videoPlayerVolume";
|
|
14
|
+
readonly fallback: 1;
|
|
15
|
+
};
|
|
16
|
+
readonly speed: {
|
|
17
|
+
readonly options: readonly [0.5, 0.75, 1, 1.25, 1.5, 2];
|
|
18
|
+
readonly defaultRate: 1;
|
|
19
|
+
};
|
|
20
|
+
readonly texts: {
|
|
21
|
+
readonly loading: "비디오를 로딩 중입니다...";
|
|
22
|
+
readonly errorTitle: "비디오를 재생할 수 없습니다";
|
|
23
|
+
readonly errorDescription: "비디오 파일을 확인해주세요.";
|
|
24
|
+
readonly errorRetry: "다시 시도";
|
|
25
|
+
};
|
|
26
|
+
readonly aria: {
|
|
27
|
+
readonly progress: "비디오 진행률";
|
|
28
|
+
readonly play: "재생";
|
|
29
|
+
readonly pause: "일시정지";
|
|
30
|
+
readonly fullscreenEnter: "전체화면";
|
|
31
|
+
readonly fullscreenExit: "전체화면 종료";
|
|
32
|
+
readonly speed: "재생 속도 조절";
|
|
33
|
+
readonly mute: "음소거";
|
|
34
|
+
readonly unmute: "음소거 해제";
|
|
35
|
+
readonly back: "뒤로가기";
|
|
36
|
+
readonly share: "공유";
|
|
37
|
+
};
|
|
38
|
+
readonly icons: {
|
|
39
|
+
readonly play: "Play";
|
|
40
|
+
readonly pause: "Pause";
|
|
41
|
+
readonly back: "BackButton";
|
|
42
|
+
readonly share: "Share";
|
|
43
|
+
readonly volumeOn: "VolumeUp";
|
|
44
|
+
readonly volumeOff: "VolumeOff";
|
|
45
|
+
readonly fullscreenEnter: "FullScreen";
|
|
46
|
+
readonly fullscreenExit: "FullScreenClose";
|
|
47
|
+
};
|
|
48
|
+
};
|
|
@@ -0,0 +1,89 @@
|
|
|
1
|
+
/** Button */
|
|
2
|
+
export { default as Button } from '../components/Button/Button';
|
|
3
|
+
/** Comment */
|
|
4
|
+
export { default as Comment } from '../components/Comment/Comment';
|
|
5
|
+
/** Icon */
|
|
6
|
+
export { Icon } from '../components/Icon/Icon';
|
|
7
|
+
export { IconProvider } from '../components/Icon/context';
|
|
8
|
+
/** HelperText */
|
|
9
|
+
export { default as HelperText } from '../components/HelperText/HelperText';
|
|
10
|
+
/** Divider */
|
|
11
|
+
export { default as Divider } from '../components/Divider/Divider';
|
|
12
|
+
/** Accordion */
|
|
13
|
+
export { default as Accordion } from '../components/Accordion/Accordion';
|
|
14
|
+
/** Breadcrumb */
|
|
15
|
+
export { default as Breadcrumb } from '../components/Breadcrumb/Breadcrumb';
|
|
16
|
+
/** Slider */
|
|
17
|
+
export { default as Slider } from '../components/Slider/Slider';
|
|
18
|
+
/** Stepper */
|
|
19
|
+
export { default as Stepper } from '../components/Stepper/Stepper';
|
|
20
|
+
/** Badge */
|
|
21
|
+
export { default as Badge } from '../components/Badge/Badge';
|
|
22
|
+
/** Avatar */
|
|
23
|
+
export { default as Avatar } from '../components/Avatar/Avatar';
|
|
24
|
+
/** ScrollSpy */
|
|
25
|
+
export { default as ScrollSpy } from '../components/ScrollSpy/ScrollSpy';
|
|
26
|
+
/** Cascader */
|
|
27
|
+
export { default as Cascader } from '../components/Cascader/Cascader';
|
|
28
|
+
/** CheckBox */
|
|
29
|
+
export { default as CheckBox } from '../components/Form/CheckBox/CheckBox';
|
|
30
|
+
/** Tab */
|
|
31
|
+
export { default as Tab } from '../components/Tab/Tab';
|
|
32
|
+
/** Dropdown */
|
|
33
|
+
export { default as Dropdown } from '../components/Form/Dropdown/Dropdown';
|
|
34
|
+
/** OTPInput */
|
|
35
|
+
export { default as OTPInput } from '../components/Form/OTPInput/OTPInput';
|
|
36
|
+
/** Switch */
|
|
37
|
+
export { default as Switch } from '../components/Form/Switch/Switch';
|
|
38
|
+
/** Radio */
|
|
39
|
+
export { default as Radio } from '../components/Form/Radio/Radio';
|
|
40
|
+
/** TextInput */
|
|
41
|
+
export { default as TextInput } from '../components/Form/TextInput/TextInput';
|
|
42
|
+
/** TextArea */
|
|
43
|
+
export { default as TextArea } from '../components/Form/TextArea/TextArea';
|
|
44
|
+
/** LazyImage */
|
|
45
|
+
export { default as LazyImage } from '../components/LazyImage/LazyImage';
|
|
46
|
+
/** Calendar */
|
|
47
|
+
export { default as Calendar } from '../components/Calendar/Calendar';
|
|
48
|
+
export { CalendarContext } from '../components/Calendar/Calendar.context';
|
|
49
|
+
/** Chart */
|
|
50
|
+
export { default as Chart } from '../components/Chart/Chart';
|
|
51
|
+
/** Quill Editor */
|
|
52
|
+
export { default as Editor } from '../components/Editor/Editor';
|
|
53
|
+
/** Table */
|
|
54
|
+
export { default as Table } from '../components/Table/Table';
|
|
55
|
+
/** Weekly Calendar */
|
|
56
|
+
export { default as WeeklyCalendar } from '../components/WeeklyCalendar/WeeklyCalendar';
|
|
57
|
+
export { WeeklyCalendarContext } from '../components/WeeklyCalendar/WeeklyCalendar.context';
|
|
58
|
+
/** MobilePicker */
|
|
59
|
+
export { default as MobilePicker } from '../components/MobilePicker/MobilePicker';
|
|
60
|
+
/** LNB */
|
|
61
|
+
export { default as LNB } from '../components/LNB/LNB';
|
|
62
|
+
export { makeNavigation } from '../components/LNB/makeNavigation';
|
|
63
|
+
/** Pagination */
|
|
64
|
+
export { default as Pagination } from '../components/Pagination/Pagination';
|
|
65
|
+
/** BarCode */
|
|
66
|
+
export { default as BarCode } from '../components/BarCode/BarCode';
|
|
67
|
+
/** QRCode */
|
|
68
|
+
export { default as QRCode } from '../components/QRCode/QRCode';
|
|
69
|
+
/** Chips */
|
|
70
|
+
export { default as Chips } from '../components/Chips/Chips';
|
|
71
|
+
/** Label */
|
|
72
|
+
export { default as Label } from '../components/Label/Label';
|
|
73
|
+
/** ScrollCalendar */
|
|
74
|
+
export { default as ScrollCalendar } from '../components/ScrollCalendar/ScrollCalendar';
|
|
75
|
+
export { ScrollCalendarContext } from '../components/ScrollCalendar/ScrollCalendar.context';
|
|
76
|
+
/** Sheet */
|
|
77
|
+
export { default as Sheet } from '../components/Sheet/Sheet';
|
|
78
|
+
/** Modal */
|
|
79
|
+
export { default as Modal } from '../components/Modal/Modal';
|
|
80
|
+
/** Popup */
|
|
81
|
+
export { default as Popup } from '../components/Popup/Popup';
|
|
82
|
+
/** TimeInput */
|
|
83
|
+
export { default as TimeInput } from '../components/TimeInput/TimeInput';
|
|
84
|
+
/** List */
|
|
85
|
+
export { default as List } from '../components/List/List';
|
|
86
|
+
/** Thumbnail */
|
|
87
|
+
export { default as Thumbnail } from '../components/Thumbnail/Thumbnail';
|
|
88
|
+
export { default as VideoPlayer } from '../components/VideoPlayer/VideoPlayer';
|
|
89
|
+
export {};
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
/** 타입 export만 모읍니다. (type-only export) */
|
|
2
|
+
/** Table */
|
|
3
|
+
export type { TableRootProps } from '../components/Table/Table';
|
|
4
|
+
/** LNB */
|
|
5
|
+
export type { Navigation } from '../components/LNB/LNB';
|
|
6
|
+
/** Badge */
|
|
7
|
+
export type { BadgeRootProps, BadgeRenderProps, } from '../components/Badge/Badge';
|
|
8
|
+
/** QRCode */
|
|
9
|
+
export type { QRCodeRef } from '../components/QRCode/QRCode';
|
|
10
|
+
/** BarCode */
|
|
11
|
+
export type { BarcodeActions } from '../components/BarCode/BarCode';
|
|
12
|
+
/** Stepper */
|
|
13
|
+
export type { StepperProviderProps } from '../components/Stepper/Stepper';
|
|
14
|
+
/** Sheet */
|
|
15
|
+
export type { SheetRootProps } from '../components/Sheet/Sheet';
|
|
16
|
+
/** Popup */
|
|
17
|
+
export type { PopupRootProps } from '../components/Popup/Popup';
|
|
18
|
+
/** Thumbnail */
|
|
19
|
+
export type { ThumbnailRootProps } from '../components/Thumbnail/Thumbnail';
|
|
20
|
+
/** Calendar */
|
|
21
|
+
export type { CalendarContextType } from '../components/Calendar/Calendar.context';
|
|
22
|
+
/** ScrollCalendar */
|
|
23
|
+
export type { ScrollCalendarContextType } from '../components/ScrollCalendar/ScrollCalendar.context';
|
|
24
|
+
/** Cascader */
|
|
25
|
+
export type { CascaderOption } from '../components/Cascader/Cascader.context';
|
|
26
|
+
/** WeeklyCalendar */
|
|
27
|
+
export type { WeeklyCalendarContextType, EventItemAsProps, EventItemPopperAsProps, } from '../components/WeeklyCalendar/WeeklyCalendar.context';
|
|
28
|
+
export type { VideoPlayerProps, VideoPlayerRootProps, VideoPlayerControls, VideoPlayerTexts, VideoPlayerAria, VideoPlayerIcons, VideoPlayerEvents, } from '../components/VideoPlayer/VideoPlayer';
|
|
29
|
+
export type { VideoPlayerStoreApi, VideoPlayerImageComponent, VideoPlayerImageProps, VideoPlayerStore, VideoPlayerState, VideoPlayerActions, VideoPlayerStoreConfig, } from '../components/VideoPlayer/context';
|
|
30
|
+
/** Icon */
|
|
31
|
+
export type { IconProviderProps, IconRegistry, } from '../components/Icon/context';
|
|
32
|
+
/** Editor */
|
|
33
|
+
export type { EditorContextValue, CustomImageUploadHandler, UploadedImageInfo, } from '../components/Editor/Editor.context';
|
|
34
|
+
export type { EditorProps, CustomFont, CustomFontSource, } from '../components/Editor/Editor';
|
|
35
|
+
export type { ToolbarOptions, ToolbarGroup, ToolbarItem, ToolbarSimpleFormat, ToolbarComplexFormat, ToolbarSizeValue, } from '../components/Editor/constants/editor.constants';
|
|
36
|
+
export {};
|
|
@@ -8,7 +8,10 @@ class p {
|
|
|
8
8
|
n(this, "quill");
|
|
9
9
|
n(this, "img", null);
|
|
10
10
|
n(this, "box", null);
|
|
11
|
-
n(this, "startPos", {
|
|
11
|
+
n(this, "startPos", {
|
|
12
|
+
x: 0,
|
|
13
|
+
y: 0
|
|
14
|
+
});
|
|
12
15
|
n(this, "startSize", {
|
|
13
16
|
width: 0,
|
|
14
17
|
height: 0
|
|
@@ -26,7 +29,10 @@ class p {
|
|
|
26
29
|
n(this, "initResize", (e) => {
|
|
27
30
|
if (typeof document > "u" || (e.preventDefault(), !this.img || !this.box)) return;
|
|
28
31
|
const t = e.target;
|
|
29
|
-
this.currentHandle = t.dataset.corner || "se", this.startPos = {
|
|
32
|
+
this.currentHandle = t.dataset.corner || "se", this.startPos = {
|
|
33
|
+
x: e.clientX,
|
|
34
|
+
y: e.clientY
|
|
35
|
+
}, this.startSize = {
|
|
30
36
|
width: this.img.width,
|
|
31
37
|
height: this.img.height
|
|
32
38
|
}, document.addEventListener("mousemove", this.performResize), document.addEventListener("mouseup", this.stopResize);
|
|
@@ -82,20 +88,12 @@ class p {
|
|
|
82
88
|
const e = a.find(this.img);
|
|
83
89
|
if (e && e.parent && e.domNode) {
|
|
84
90
|
if (e === this.quill) {
|
|
85
|
-
console.error(
|
|
86
|
-
"Quill.find returned the Quill instance itself, not a Blot for image",
|
|
87
|
-
this.img
|
|
88
|
-
);
|
|
91
|
+
console.error("Quill.find returned the Quill instance itself, not a Blot for image", this.img);
|
|
89
92
|
return;
|
|
90
93
|
}
|
|
91
94
|
try {
|
|
92
95
|
const t = this.quill.getIndex(e);
|
|
93
|
-
this.quill.deleteText(t, 1), this.quill.insertEmbed(
|
|
94
|
-
t,
|
|
95
|
-
"image",
|
|
96
|
-
this.img.getAttribute("src") || "",
|
|
97
|
-
"user"
|
|
98
|
-
);
|
|
96
|
+
this.quill.deleteText(t, 1), this.quill.insertEmbed(t, "image", this.img.getAttribute("src") || "", "user");
|
|
99
97
|
const s = {
|
|
100
98
|
width: this.img.style.width,
|
|
101
99
|
height: this.img.style.height
|
|
@@ -105,11 +103,7 @@ class p {
|
|
|
105
103
|
console.error("Error processing blot in saveToDelta:", t, e);
|
|
106
104
|
}
|
|
107
105
|
} else
|
|
108
|
-
console.error(
|
|
109
|
-
"Could not find a valid blot for image (missing parent or domNode)",
|
|
110
|
-
this.img,
|
|
111
|
-
e
|
|
112
|
-
);
|
|
106
|
+
console.error("Could not find a valid blot for image (missing parent or domNode)", this.img, e);
|
|
113
107
|
}
|
|
114
108
|
}
|
|
115
109
|
const g = 50, x = 50, b = 1200, y = 1200;
|
|
@@ -118,14 +112,23 @@ class w {
|
|
|
118
112
|
n(this, "quill");
|
|
119
113
|
n(this, "media", null);
|
|
120
114
|
n(this, "box", null);
|
|
121
|
-
n(this, "startPos", {
|
|
122
|
-
|
|
115
|
+
n(this, "startPos", {
|
|
116
|
+
x: 0,
|
|
117
|
+
y: 0
|
|
118
|
+
});
|
|
119
|
+
n(this, "startSize", {
|
|
120
|
+
width: 0,
|
|
121
|
+
height: 0
|
|
122
|
+
});
|
|
123
123
|
n(this, "currentHandle", null);
|
|
124
124
|
n(this, "aspectRatio", 1);
|
|
125
125
|
n(this, "initResize", (e) => {
|
|
126
126
|
if (typeof document > "u" || (e.preventDefault(), !this.media || !this.box)) return;
|
|
127
127
|
const t = e.target;
|
|
128
|
-
this.currentHandle = t.dataset.corner || "se", this.startPos = {
|
|
128
|
+
this.currentHandle = t.dataset.corner || "se", this.startPos = {
|
|
129
|
+
x: e.clientX,
|
|
130
|
+
y: e.clientY
|
|
131
|
+
}, this.startSize = {
|
|
129
132
|
width: this.media.clientWidth,
|
|
130
133
|
height: this.media.clientHeight
|
|
131
134
|
}, document.addEventListener("mousemove", this.performResize), document.addEventListener("mouseup", this.stopResize);
|
|
@@ -218,32 +221,20 @@ class w {
|
|
|
218
221
|
const e = a.find(this.media);
|
|
219
222
|
if (e && e.parent && e.domNode) {
|
|
220
223
|
if (e === this.quill) {
|
|
221
|
-
console.error(
|
|
222
|
-
"Quill.find returned the Quill instance itself, not a Blot for media",
|
|
223
|
-
this.media
|
|
224
|
-
);
|
|
224
|
+
console.error("Quill.find returned the Quill instance itself, not a Blot for media", this.media);
|
|
225
225
|
return;
|
|
226
226
|
}
|
|
227
227
|
try {
|
|
228
228
|
const t = this.quill.getIndex(e), s = this.media.getAttribute("src") || "", i = this.media.tagName.toLowerCase();
|
|
229
|
-
this.quill.deleteText(t, 1), i === "img" ? this.quill.insertEmbed(t, "image", s, "user") : (i === "video" || i === "iframe") && this.quill.insertEmbed(t, "video", s, "user"), this.quill.formatText(
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
width: this.media.style.width,
|
|
234
|
-
height: this.media.style.height
|
|
235
|
-
},
|
|
236
|
-
"user"
|
|
237
|
-
);
|
|
229
|
+
this.quill.deleteText(t, 1), i === "img" ? this.quill.insertEmbed(t, "image", s, "user") : (i === "video" || i === "iframe") && this.quill.insertEmbed(t, "video", s, "user"), this.quill.formatText(t, 1, {
|
|
230
|
+
width: this.media.style.width,
|
|
231
|
+
height: this.media.style.height
|
|
232
|
+
}, "user");
|
|
238
233
|
} catch (t) {
|
|
239
234
|
console.error("Error processing blot in saveToDelta:", t, e);
|
|
240
235
|
}
|
|
241
236
|
} else
|
|
242
|
-
console.error(
|
|
243
|
-
"Could not find a valid blot for media (missing parent or domNode)",
|
|
244
|
-
this.media,
|
|
245
|
-
e
|
|
246
|
-
);
|
|
237
|
+
console.error("Could not find a valid blot for media (missing parent or domNode)", this.media, e);
|
|
247
238
|
}
|
|
248
239
|
}
|
|
249
240
|
const R = {
|