@iyulab/components 0.2.2 → 0.3.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.
Files changed (70) hide show
  1. package/CHANGELOG.md +133 -118
  2. package/LICENSE +20 -20
  3. package/README.md +283 -283
  4. package/dist/assets/icons/arrow-down.svg.js +1 -1
  5. package/dist/assets/icons/arrow-repeat.svg.js +1 -1
  6. package/dist/assets/icons/arrow-up.svg.js +1 -1
  7. package/dist/assets/icons/ban.svg.js +1 -1
  8. package/dist/assets/icons/bell-fill.svg.js +1 -1
  9. package/dist/assets/icons/box-arrow-up-right.svg.js +1 -1
  10. package/dist/assets/icons/check-circle-fill.svg.js +1 -1
  11. package/dist/assets/icons/check-lg.svg.js +1 -1
  12. package/dist/assets/icons/chevron-down.svg.js +1 -1
  13. package/dist/assets/icons/chevron-left.svg.js +1 -1
  14. package/dist/assets/icons/chevron-right.svg.js +1 -1
  15. package/dist/assets/icons/chevron-up.svg.js +1 -1
  16. package/dist/assets/icons/copy.svg.js +1 -1
  17. package/dist/assets/icons/dash-lg.svg.js +1 -1
  18. package/dist/assets/icons/exclamation-circle-fill.svg.js +1 -1
  19. package/dist/assets/icons/exclamation-triangle-fill.svg.js +1 -1
  20. package/dist/assets/icons/eye-slash.svg.js +1 -1
  21. package/dist/assets/icons/eye.svg.js +1 -1
  22. package/dist/assets/icons/file-earmark.svg.js +1 -1
  23. package/dist/assets/icons/flag.svg.js +1 -1
  24. package/dist/assets/icons/globe.svg.js +1 -1
  25. package/dist/assets/icons/hand-thumbs-down-fill.svg.js +1 -1
  26. package/dist/assets/icons/hand-thumbs-down.svg.js +1 -1
  27. package/dist/assets/icons/hand-thumbs-up-fill.svg.js +1 -1
  28. package/dist/assets/icons/hand-thumbs-up.svg.js +1 -1
  29. package/dist/assets/icons/info-circle-fill.svg.js +1 -1
  30. package/dist/assets/icons/lightbulb-fill.svg.js +1 -1
  31. package/dist/assets/icons/lightbulb-off.svg.js +1 -1
  32. package/dist/assets/icons/lightbulb.svg.js +1 -1
  33. package/dist/assets/icons/mic-fill.svg.js +1 -1
  34. package/dist/assets/icons/mic-mute-fill.svg.js +1 -1
  35. package/dist/assets/icons/paperclip.svg.js +1 -1
  36. package/dist/assets/icons/pencil-square.svg.js +1 -1
  37. package/dist/assets/icons/plus-lg.svg.js +1 -1
  38. package/dist/assets/icons/search.svg.js +1 -1
  39. package/dist/assets/icons/share.svg.js +1 -1
  40. package/dist/assets/icons/stop-circle.svg.js +1 -1
  41. package/dist/assets/icons/tools.svg.js +1 -1
  42. package/dist/assets/icons/x-lg.svg.js +1 -1
  43. package/dist/assets/styles/dark.css +129 -129
  44. package/dist/assets/styles/dark.css.js +1 -1
  45. package/dist/assets/styles/light.css +129 -129
  46. package/dist/assets/styles/light.css.js +1 -1
  47. package/dist/components/card/UCard.component.d.ts +21 -0
  48. package/dist/components/card/UCard.component.js +66 -0
  49. package/dist/components/card/UCard.d.ts +7 -0
  50. package/dist/components/card/UCard.js +5 -0
  51. package/dist/components/card/UCard.styles.d.ts +1 -0
  52. package/dist/components/card/UCard.styles.js +76 -0
  53. package/dist/components/carousel/UCarousel.component.d.ts +67 -0
  54. package/dist/components/carousel/UCarousel.component.js +243 -0
  55. package/dist/components/carousel/UCarousel.d.ts +7 -0
  56. package/dist/components/carousel/UCarousel.js +5 -0
  57. package/dist/components/carousel/UCarousel.styles.d.ts +1 -0
  58. package/dist/components/carousel/UCarousel.styles.js +113 -0
  59. package/dist/components/icon/UIcon.component.d.ts +4 -1
  60. package/dist/components/input/UInput.component.d.ts +8 -0
  61. package/dist/components/input/UInput.component.js +17 -0
  62. package/dist/index.d.ts +2 -0
  63. package/dist/index.js +4 -0
  64. package/dist/react-components/UCard.d.ts +8 -0
  65. package/dist/react-components/UCard.js +10 -0
  66. package/dist/react-components/UCarousel.d.ts +8 -0
  67. package/dist/react-components/UCarousel.js +10 -0
  68. package/dist/react-components/index.d.ts +2 -0
  69. package/dist/react-components/index.js +2 -0
  70. package/package.json +71 -60
@@ -0,0 +1,243 @@
1
+ import { html } from 'lit';
2
+ import { property, state } from 'lit/decorators.js';
3
+ import { BaseElement } from '../BaseElement.js';
4
+ import { UButton } from '../button/UButton.component.js';
5
+ import { UIcon } from '../icon/UIcon.component.js';
6
+ import { styles } from './UCarousel.styles.js';
7
+
8
+ var __defProp = Object.defineProperty;
9
+ var __decorateClass = (decorators, target, key, kind) => {
10
+ var result = void 0 ;
11
+ for (var i = decorators.length - 1, decorator; i >= 0; i--)
12
+ if (decorator = decorators[i])
13
+ result = (decorator(target, key, result) ) || result;
14
+ if (result) __defProp(target, key, result);
15
+ return result;
16
+ };
17
+ class UCarousel extends BaseElement {
18
+ constructor() {
19
+ super(...arguments);
20
+ this.currentIndex = 0;
21
+ this.autoplay = false;
22
+ this.autoplayInterval = 3e3;
23
+ this.navigation = true;
24
+ this.pagination = true;
25
+ this.loop = true;
26
+ this.draggable = false;
27
+ this.slidesPerView = 1;
28
+ this.slidesPerMove = 1;
29
+ this.gap = 0;
30
+ this._slideCount = 0;
31
+ this._isDragging = false;
32
+ this._dragOffset = 0;
33
+ this._dragStartX = 0;
34
+ this._dragStartTime = 0;
35
+ this.handleDragStart = (e) => {
36
+ e.preventDefault();
37
+ };
38
+ this.handlePointerDown = (e) => {
39
+ if (e.button !== 0) return;
40
+ e.preventDefault();
41
+ this._isDragging = true;
42
+ this._dragStartX = e.clientX;
43
+ this._dragOffset = 0;
44
+ this._dragStartTime = Date.now();
45
+ if (this.autoplay) this.stopAutoplay();
46
+ const wrapper = e.currentTarget;
47
+ wrapper.setPointerCapture(e.pointerId);
48
+ };
49
+ this.handlePointerMove = (e) => {
50
+ if (!this._isDragging) return;
51
+ const wrapper = e.currentTarget;
52
+ this._dragOffset = (e.clientX - this._dragStartX) / wrapper.offsetWidth * 100;
53
+ };
54
+ this.handlePointerUp = (e) => {
55
+ if (!this._isDragging) return;
56
+ const elapsed = Date.now() - this._dragStartTime;
57
+ const absDrag = Math.abs(this._dragOffset);
58
+ if (absDrag > 20 || absDrag > 5 && elapsed < 300) {
59
+ if (this._dragOffset < 0) this.next();
60
+ else this.prev();
61
+ }
62
+ this._isDragging = false;
63
+ this._dragOffset = 0;
64
+ if (this.autoplay) this.startAutoplay();
65
+ const wrapper = e.currentTarget;
66
+ wrapper.releasePointerCapture(e.pointerId);
67
+ };
68
+ }
69
+ static {
70
+ this.styles = [super.styles, styles];
71
+ }
72
+ static {
73
+ this.dependencies = {
74
+ "u-button": UButton,
75
+ "u-icon": UIcon
76
+ };
77
+ }
78
+ get _perView() {
79
+ return Math.max(1, this.slidesPerView);
80
+ }
81
+ get _perMove() {
82
+ return Math.max(1, this.slidesPerMove);
83
+ }
84
+ get _maxIndex() {
85
+ return Math.max(0, this._slideCount - this._perView);
86
+ }
87
+ get _pageCount() {
88
+ return this._maxIndex <= 0 ? 1 : Math.ceil(this._maxIndex / this._perMove) + 1;
89
+ }
90
+ get _currentPage() {
91
+ return this.currentIndex >= this._maxIndex ? this._pageCount - 1 : Math.floor(this.currentIndex / this._perMove);
92
+ }
93
+ connectedCallback() {
94
+ super.connectedCallback();
95
+ if (this.autoplay) this.startAutoplay();
96
+ }
97
+ disconnectedCallback() {
98
+ this.stopAutoplay();
99
+ super.disconnectedCallback();
100
+ }
101
+ willUpdate(changedProperties) {
102
+ super.willUpdate(changedProperties);
103
+ if (changedProperties.has("slidesPerView")) {
104
+ this.style.setProperty("--slides-per-view", String(this._perView));
105
+ }
106
+ if (changedProperties.has("gap")) {
107
+ this.style.setProperty("--slide-gap", `${this.gap}px`);
108
+ }
109
+ }
110
+ updated(changedProperties) {
111
+ super.updated(changedProperties);
112
+ if (changedProperties.has("autoplay") || changedProperties.has("autoplayInterval")) {
113
+ if (this.autoplay) this.startAutoplay();
114
+ else this.stopAutoplay();
115
+ }
116
+ }
117
+ render() {
118
+ const pct = -(this.currentIndex * (100 / this._perView)) + this._dragOffset;
119
+ const gapPx = this.gap > 0 ? -(this.currentIndex * this.gap / this._perView) : 0;
120
+ const transform = gapPx ? `translateX(calc(${pct}% + ${gapPx}px))` : `translateX(${pct}%)`;
121
+ const style = `transform: ${transform}${this._isDragging ? "; transition: none" : ""}`;
122
+ return html`
123
+ <div class="slides-wrapper"
124
+ @dragstart=${this.handleDragStart}
125
+ @pointerdown=${this.draggable ? this.handlePointerDown : null}
126
+ @pointermove=${this.draggable ? this.handlePointerMove : null}
127
+ @pointerup=${this.draggable ? this.handlePointerUp : null}
128
+ @pointerleave=${this.draggable ? this.handlePointerUp : null}>
129
+ <div part="slides" class="slides" style="${style}">
130
+ <slot @slotchange=${this.handleSlotChange}></slot>
131
+ </div>
132
+ </div>
133
+
134
+ <u-button part="prev-button" class="nav-button prev" variant="borderless"
135
+ ?hidden=${!this.navigation}
136
+ ?disabled=${!this.loop && this.currentIndex <= 0}
137
+ @click=${this.prev}>
138
+ <u-icon lib="internal" name="chevron-left"></u-icon>
139
+ </u-button>
140
+ <u-button part="next-button" class="nav-button next" variant="borderless"
141
+ ?hidden=${!this.navigation}
142
+ ?disabled=${!this.loop && this.currentIndex >= this._maxIndex}
143
+ @click=${this.next}>
144
+ <u-icon lib="internal" name="chevron-right"></u-icon>
145
+ </u-button>
146
+
147
+ <div part="indicator" class="indicator"
148
+ ?hidden=${!this.pagination || !this._slideCount}>
149
+ ${Array.from({ length: this._pageCount }, (_, i) => html`
150
+ <button part="dot"
151
+ class="dot ${i === this._currentPage ? "active" : ""}"
152
+ @click=${() => this.goTo(Math.min(i * this._perMove, this._maxIndex))}>
153
+ </button>
154
+ `)}
155
+ </div>
156
+ `;
157
+ }
158
+ /** 이전 슬라이드로 이동 */
159
+ prev() {
160
+ const target = Math.max(0, this.currentIndex - this._perMove);
161
+ if (target !== this.currentIndex) {
162
+ this.goTo(target);
163
+ } else if (this.loop) {
164
+ this.goTo(Math.min((this._pageCount - 1) * this._perMove, this._maxIndex));
165
+ }
166
+ }
167
+ /** 다음 슬라이드로 이동 */
168
+ next() {
169
+ const target = Math.min(this._maxIndex, this.currentIndex + this._perMove);
170
+ if (target !== this.currentIndex) {
171
+ this.goTo(target);
172
+ } else if (this.loop) {
173
+ this.goTo(0);
174
+ }
175
+ }
176
+ /** 지정한 인덱스로 이동 */
177
+ goTo(index) {
178
+ if (index < 0 || index > this._maxIndex || index === this.currentIndex) return;
179
+ this.currentIndex = index;
180
+ this.emit("u-change", {
181
+ currentIndex: this.currentIndex
182
+ });
183
+ if (this.autoplay) this.startAutoplay();
184
+ }
185
+ handleSlotChange(e) {
186
+ const slot = e.target;
187
+ this._slideCount = slot.assignedElements().length;
188
+ if (this.currentIndex >= this._slideCount) {
189
+ this.currentIndex = Math.max(0, this._slideCount - 1);
190
+ }
191
+ }
192
+ startAutoplay() {
193
+ this.stopAutoplay();
194
+ this._autoplayTimer = window.setInterval(() => this.next(), this.autoplayInterval);
195
+ }
196
+ stopAutoplay() {
197
+ if (this._autoplayTimer) {
198
+ clearInterval(this._autoplayTimer);
199
+ this._autoplayTimer = void 0;
200
+ }
201
+ }
202
+ }
203
+ __decorateClass([
204
+ property({ type: Number, reflect: true, attribute: "current-index" })
205
+ ], UCarousel.prototype, "currentIndex");
206
+ __decorateClass([
207
+ property({ type: Boolean, reflect: true })
208
+ ], UCarousel.prototype, "autoplay");
209
+ __decorateClass([
210
+ property({ type: Number, attribute: "autoplay-interval" })
211
+ ], UCarousel.prototype, "autoplayInterval");
212
+ __decorateClass([
213
+ property({ type: Boolean, reflect: true })
214
+ ], UCarousel.prototype, "navigation");
215
+ __decorateClass([
216
+ property({ type: Boolean, reflect: true })
217
+ ], UCarousel.prototype, "pagination");
218
+ __decorateClass([
219
+ property({ type: Boolean, reflect: true })
220
+ ], UCarousel.prototype, "loop");
221
+ __decorateClass([
222
+ property({ type: Boolean, reflect: true })
223
+ ], UCarousel.prototype, "draggable");
224
+ __decorateClass([
225
+ property({ type: Number, reflect: true, attribute: "slides-per-view" })
226
+ ], UCarousel.prototype, "slidesPerView");
227
+ __decorateClass([
228
+ property({ type: Number, attribute: "slides-per-move" })
229
+ ], UCarousel.prototype, "slidesPerMove");
230
+ __decorateClass([
231
+ property({ type: Number, reflect: true })
232
+ ], UCarousel.prototype, "gap");
233
+ __decorateClass([
234
+ state()
235
+ ], UCarousel.prototype, "_slideCount");
236
+ __decorateClass([
237
+ state()
238
+ ], UCarousel.prototype, "_isDragging");
239
+ __decorateClass([
240
+ state()
241
+ ], UCarousel.prototype, "_dragOffset");
242
+
243
+ export { UCarousel };
@@ -0,0 +1,7 @@
1
+ import { UCarousel } from './UCarousel.component.js';
2
+ declare global {
3
+ interface HTMLElementTagNameMap {
4
+ "u-carousel": UCarousel;
5
+ }
6
+ }
7
+ export { UCarousel };
@@ -0,0 +1,5 @@
1
+ import { UCarousel } from './UCarousel.component.js';
2
+
3
+ UCarousel.define("u-carousel");
4
+
5
+ export { UCarousel };
@@ -0,0 +1 @@
1
+ export declare const styles: import('lit').CSSResult;
@@ -0,0 +1,113 @@
1
+ import { css } from 'lit';
2
+
3
+ const styles = css`
4
+ /* ── Host ── */
5
+ :host {
6
+ --slide-gap: 0px;
7
+ --slides-per-view: 1;
8
+ }
9
+ :host {
10
+ display: block;
11
+ position: relative;
12
+ width: 100%;
13
+ overflow: hidden;
14
+ box-sizing: border-box;
15
+ }
16
+
17
+ /* ── Draggable ── */
18
+ :host([draggable]) .slides-wrapper {
19
+ cursor: grab;
20
+ user-select: none;
21
+ }
22
+ :host([draggable]) .slides-wrapper:active {
23
+ cursor: grabbing;
24
+ }
25
+ :host([draggable]) ::slotted(*) {
26
+ -webkit-user-drag: none;
27
+ user-select: none;
28
+ }
29
+
30
+ /* ── Slides ── */
31
+ .slides-wrapper {
32
+ position: relative;
33
+ width: 100%;
34
+ height: 100%;
35
+ overflow: hidden;
36
+ touch-action: pan-y;
37
+ }
38
+
39
+ .slides {
40
+ display: flex;
41
+ width: 100%;
42
+ height: 100%;
43
+ gap: var(--slide-gap, 0px);
44
+ transition: transform 0.3s ease-in-out;
45
+ }
46
+
47
+ ::slotted(*) {
48
+ flex: 0 0 calc(
49
+ (100% - (var(--slides-per-view) - 1) * var(--slide-gap, 0px))
50
+ / var(--slides-per-view)
51
+ );
52
+ min-width: 0;
53
+ height: 100%;
54
+ box-sizing: border-box;
55
+ }
56
+
57
+ /* ── Navigation ── */
58
+ .nav-button {
59
+ position: absolute;
60
+ z-index: 10;
61
+ top: 50%;
62
+ transform: translateY(-50%);
63
+ width: 40px;
64
+ height: 40px;
65
+ display: flex;
66
+ align-items: center;
67
+ justify-content: center;
68
+ border-radius: 50%;
69
+ font-size: 16px;
70
+ background-color: var(--u-panel-bg-color, #fff);
71
+ box-shadow: 0 2px 8px var(--u-shadow-color-normal, rgba(0, 0, 0, 0.12));
72
+ opacity: 0.9;
73
+ }
74
+ .nav-button:hover {
75
+ opacity: 1;
76
+ background-color: var(--u-bg-color-hover, #f3f4f6);
77
+ }
78
+
79
+ .nav-button.prev { left: 16px; }
80
+ .nav-button.next { right: 16px; }
81
+
82
+ /* ── Indicator ── */
83
+ .indicator {
84
+ position: absolute;
85
+ z-index: 10;
86
+ bottom: 16px;
87
+ left: 50%;
88
+ transform: translateX(-50%);
89
+ display: flex;
90
+ gap: 8px;
91
+ }
92
+
93
+ .dot {
94
+ width: 10px;
95
+ height: 10px;
96
+ padding: 0;
97
+ border: none;
98
+ border-radius: 50%;
99
+ background-color: var(--u-neutral-400, rgba(0, 0, 0, 0.3));
100
+ cursor: pointer;
101
+ transition: all 0.2s ease;
102
+ }
103
+ .dot:hover {
104
+ background-color: var(--u-neutral-200, rgba(0, 0, 0, 0.5));
105
+ }
106
+ .dot.active {
107
+ background-color: var(--u-neutral-100, rgba(0, 0, 0, 0.8));
108
+ width: 24px;
109
+ border-radius: 5px;
110
+ }
111
+ `;
112
+
113
+ export { styles };
@@ -1,3 +1,4 @@
1
+ import { nothing } from 'lit';
1
2
  import { BaseElement } from '../BaseElement.js';
2
3
  export type IconLibrary = "internal" | "default" | (string & {});
3
4
  /**
@@ -18,7 +19,9 @@ export declare class UIcon extends BaseElement {
18
19
  * 사용할 아이콘의 이름을 지정합니다.
19
20
  */
20
21
  name?: string;
21
- render(): import('lit-html/directive.js').DirectiveResult<typeof import('lit-html/directives/until.js').UntilDirective>;
22
+ render(): import('lit-html/directive.js').DirectiveResult<{
23
+ new (_partInfo: import('lit-html/directive.js').PartInfo): import('lit-html/directives/until.js').UntilDirective<typeof nothing | Promise<import('lit-html/directive.js').DirectiveResult<typeof import('lit-html/directives/unsafe-html.js').UnsafeHTMLDirective>>>;
24
+ }>;
22
25
  /**
23
26
  * SVG 콘텐츠가 유효한 HTML인지 검사합니다.
24
27
  */
@@ -60,6 +60,14 @@ export declare class UInput extends BaseElement {
60
60
  max?: number;
61
61
  /** 증감 단위 (number, date, time 등) */
62
62
  step?: number;
63
+ /** 모바일 가상 키보드 종류 */
64
+ inputmode?: 'none' | 'text' | 'decimal' | 'numeric' | 'tel' | 'search' | 'email' | 'url';
65
+ /** 모바일 엔터 키 라벨 */
66
+ enterkeyhint?: 'enter' | 'done' | 'go' | 'next' | 'previous' | 'search' | 'send';
67
+ /** 입력 필드 표시 너비 (문자 수 기준) */
68
+ size?: number;
69
+ /** 다중 값 허용 (email 타입) */
70
+ multiple: boolean;
63
71
  protected updated(changedProperties: PropertyValues): void;
64
72
  render(): import('lit-html').TemplateResult<1>;
65
73
  /** 입력 필드에 포커스를 설정합니다. */
@@ -29,6 +29,7 @@ class UInput extends BaseElement {
29
29
  this.clearable = false;
30
30
  this.spellcheck = false;
31
31
  this.value = "";
32
+ this.multiple = false;
32
33
  /** input 이벤트 핸들러 */
33
34
  this.handleInput = (e) => {
34
35
  const input = e.target;
@@ -115,6 +116,10 @@ class UInput extends BaseElement {
115
116
  min=${ifDefined(this.min)}
116
117
  max=${ifDefined(this.max)}
117
118
  step=${ifDefined(this.step)}
119
+ inputmode=${ifDefined(this.inputmode)}
120
+ enterkeyhint=${ifDefined(this.enterkeyhint)}
121
+ size=${ifDefined(this.size)}
122
+ ?multiple=${this.multiple}
118
123
  .value=${live(this.value)}
119
124
  @input=${this.handleInput}
120
125
  @change=${this.handleInputChange}
@@ -246,5 +251,17 @@ __decorateClass([
246
251
  __decorateClass([
247
252
  property({ type: Number })
248
253
  ], UInput.prototype, "step");
254
+ __decorateClass([
255
+ property({ type: String })
256
+ ], UInput.prototype, "inputmode");
257
+ __decorateClass([
258
+ property({ type: String })
259
+ ], UInput.prototype, "enterkeyhint");
260
+ __decorateClass([
261
+ property({ type: Number })
262
+ ], UInput.prototype, "size");
263
+ __decorateClass([
264
+ property({ type: Boolean })
265
+ ], UInput.prototype, "multiple");
249
266
 
250
267
  export { UInput };
package/dist/index.d.ts CHANGED
@@ -1,5 +1,7 @@
1
1
  export * from './components/alert/UAlert.js';
2
2
  export * from './components/button/UButton.js';
3
+ export * from './components/card/UCard.js';
4
+ export * from './components/carousel/UCarousel.js';
3
5
  export * from './components/dialog/UDialog.js';
4
6
  export * from './components/divider/UDivider.js';
5
7
  export * from './components/drawer/UDrawer.js';
package/dist/index.js CHANGED
@@ -1,5 +1,7 @@
1
1
  import './components/alert/UAlert.js';
2
2
  import './components/button/UButton.js';
3
+ import './components/card/UCard.js';
4
+ import './components/carousel/UCarousel.js';
3
5
  import './components/dialog/UDialog.js';
4
6
  import './components/divider/UDivider.js';
5
7
  import './components/drawer/UDrawer.js';
@@ -23,6 +25,8 @@ export { Notifier } from './utilities/Notifier.js';
23
25
  export { Theme } from './utilities/Theme.js';
24
26
  export { UAlert } from './components/alert/UAlert.component.js';
25
27
  export { UButton } from './components/button/UButton.component.js';
28
+ export { UCard } from './components/card/UCard.component.js';
29
+ export { UCarousel } from './components/carousel/UCarousel.component.js';
26
30
  export { UDialog } from './components/dialog/UDialog.component.js';
27
31
  export { UDivider } from './components/divider/UDivider.component.js';
28
32
  export { UDrawer } from './components/drawer/UDrawer.component.js';
@@ -0,0 +1,8 @@
1
+ import React from 'react';
2
+ import { UCard } from '../components/card/UCard';
3
+
4
+ export declare const UCard: React.ForwardRefExoticComponent<
5
+ Partial<UCard> & React.HTMLAttributes<UCard>
6
+ >;
7
+
8
+ export type UCardProps = React.ComponentProps<typeof UCard>;
@@ -0,0 +1,10 @@
1
+ import React from 'react';
2
+ import { createComponent } from '@lit/react';
3
+ import { UCard } from '../components/card/UCard';
4
+
5
+ export const UCard = createComponent({
6
+ react: React,
7
+ tagName: 'u-card',
8
+ elementClass: UCard,
9
+ events: {}
10
+ });
@@ -0,0 +1,8 @@
1
+ import React from 'react';
2
+ import { UCarousel } from '../components/carousel/UCarousel';
3
+
4
+ export declare const UCarousel: React.ForwardRefExoticComponent<
5
+ Partial<UCarousel> & React.HTMLAttributes<UCarousel>
6
+ >;
7
+
8
+ export type UCarouselProps = React.ComponentProps<typeof UCarousel>;
@@ -0,0 +1,10 @@
1
+ import React from 'react';
2
+ import { createComponent } from '@lit/react';
3
+ import { UCarousel } from '../components/carousel/UCarousel';
4
+
5
+ export const UCarousel = createComponent({
6
+ react: React,
7
+ tagName: 'u-carousel',
8
+ elementClass: UCarousel,
9
+ events: {}
10
+ });
@@ -7,6 +7,8 @@
7
7
 
8
8
  export { UAlert, UAlertProps } from './UAlert';
9
9
  export { UButton, UButtonProps } from './UButton';
10
+ export { UCard, UCardProps } from './UCard';
11
+ export { UCarousel, UCarouselProps } from './UCarousel';
10
12
  export { UDialog, UDialogProps } from './UDialog';
11
13
  export { UDivider, UDividerProps } from './UDivider';
12
14
  export { UDrawer, UDrawerProps } from './UDrawer';
@@ -1,5 +1,7 @@
1
1
  export { UAlert } from './UAlert.js';
2
2
  export { UButton } from './UButton.js';
3
+ export { UCard } from './UCard.js';
4
+ export { UCarousel } from './UCarousel.js';
3
5
  export { UDialog } from './UDialog.js';
4
6
  export { UDivider } from './UDivider.js';
5
7
  export { UDrawer } from './UDrawer.js';
package/package.json CHANGED
@@ -1,60 +1,71 @@
1
- {
2
- "name": "@iyulab/components",
3
- "description": "web-components library based on lit-element made by iyulab",
4
- "version": "0.2.2",
5
- "keywords": [
6
- "iyulab",
7
- "components",
8
- "web-components",
9
- "lit",
10
- "lit-element"
11
- ],
12
- "license": "MIT",
13
- "author": "iyulab",
14
- "repository": {
15
- "type": "git",
16
- "url": "https://github.com/iyulab/node-components.git"
17
- },
18
- "files": [
19
- "dist",
20
- "LICENSE",
21
- "README.md",
22
- "CHANGELOG.md",
23
- "package.json"
24
- ],
25
- "type": "module",
26
- "types": "./dist/index.d.ts",
27
- "exports": {
28
- ".": {
29
- "types": "./src/index.d.ts",
30
- "import": "./src/index.js"
31
- },
32
- "./dist/*": {
33
- "types": "./src/*.d.ts",
34
- "import": "./src/*"
35
- }
36
- },
37
- "scripts": {
38
- "test": "vite --force",
39
- "build": "eslint && vite build"
40
- },
41
- "dependencies": {
42
- "@floating-ui/dom": "^1.7.4",
43
- "@lit/react": "^1.0.8",
44
- "lit": "^3.3.2",
45
- "react": "^19.2.3",
46
- "reflect-metadata": "^0.2.2"
47
- },
48
- "devDependencies": {
49
- "@eslint/js": "^9.39.2",
50
- "@types/node": "^25.0.9",
51
- "eslint": "^9.39.2",
52
- "eslint-plugin-lit": "^2.1.1",
53
- "globals": "^17.0.0",
54
- "typescript": "^5.9.3",
55
- "typescript-eslint": "^8.53.1",
56
- "vite": "^7.3.1",
57
- "vite-plugin-dts": "^4.5.4",
58
- "vite-plugin-static-copy": "^3.1.5"
59
- }
60
- }
1
+ {
2
+ "name": "@iyulab/components",
3
+ "description": "web-components library based on lit-element made by iyulab",
4
+ "version": "0.3.0",
5
+ "keywords": [
6
+ "iyulab",
7
+ "components",
8
+ "web-components",
9
+ "lit",
10
+ "lit-element"
11
+ ],
12
+ "license": "MIT",
13
+ "author": "iyulab",
14
+ "repository": {
15
+ "type": "git",
16
+ "url": "https://github.com/iyulab/node-components.git"
17
+ },
18
+ "files": [
19
+ "dist",
20
+ "LICENSE",
21
+ "README.md",
22
+ "CHANGELOG.md",
23
+ "package.json"
24
+ ],
25
+ "type": "module",
26
+ "types": "./dist/index.d.ts",
27
+ "exports": {
28
+ ".": {
29
+ "types": "./dist/index.d.ts",
30
+ "import": "./dist/index.js"
31
+ },
32
+ "./dist/*": {
33
+ "types": "./dist/*.d.ts",
34
+ "import": "./dist/*"
35
+ }
36
+ },
37
+ "scripts": {
38
+ "test": "vite --force",
39
+ "build": "eslint && vite build"
40
+ },
41
+ "dependencies": {
42
+ "@floating-ui/dom": "^1.7.5",
43
+ "lit": "^3.3.2",
44
+ "quill": "2.0.3",
45
+ "reflect-metadata": "^0.2.2"
46
+ },
47
+ "peerDependencies": {
48
+ "@lit/react": ">=1.0.0",
49
+ "react": ">=18.0.0"
50
+ },
51
+ "peerDependenciesMeta": {
52
+ "react": {
53
+ "optional": true
54
+ },
55
+ "@lit/react": {
56
+ "optional": true
57
+ }
58
+ },
59
+ "devDependencies": {
60
+ "@eslint/js": "^10.0.1",
61
+ "@types/node": "^25.3.0",
62
+ "eslint": "^10.0.2",
63
+ "eslint-plugin-lit": "^2.2.1",
64
+ "globals": "^17.3.0",
65
+ "typescript": "^5.9.3",
66
+ "typescript-eslint": "^8.56.1",
67
+ "vite": "^7.3.1",
68
+ "vite-plugin-dts": "^4.5.4",
69
+ "vite-plugin-static-copy": "^3.2.0"
70
+ }
71
+ }