react-lookup-select 1.0.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.
@@ -0,0 +1,873 @@
1
+ /* Basic styles for react-lookup-select */
2
+
3
+ :root {
4
+ /* === CORE COLORS === */
5
+ --lookup-select-color-primary: #0066cc;
6
+ --lookup-select-color-primary-hover: #0052a3;
7
+ --lookup-select-color-primary-active: #004085;
8
+ --lookup-select-color-bg: #ffffff;
9
+ --lookup-select-color-bg-secondary: #f8f9fa;
10
+ --lookup-select-color-bg-hover: #f3f4f6;
11
+ --lookup-select-color-text: #333333;
12
+ --lookup-select-color-text-secondary: #6b7280;
13
+ --lookup-select-color-text-muted: #9ca3af;
14
+ --lookup-select-color-border: #d1d5db;
15
+ --lookup-select-color-border-focus: var(--lookup-select-color-primary);
16
+ --lookup-select-color-border-hover: #9ca3af;
17
+ --lookup-select-color-error: #dc2626;
18
+ --lookup-select-color-success: #16a34a;
19
+ --lookup-select-color-warning: #d97706;
20
+
21
+ /* === LAYOUT === */
22
+ --lookup-select-border-radius: 6px;
23
+ --lookup-select-border-radius-sm: 4px;
24
+ --lookup-select-border-radius-lg: 8px;
25
+ --lookup-select-border-width: 1px;
26
+ --lookup-select-spacing: 8px;
27
+ --lookup-select-spacing-sm: 4px;
28
+ --lookup-select-spacing-lg: 12px;
29
+ --lookup-select-spacing-xl: 16px;
30
+
31
+ /* === TYPOGRAPHY === */
32
+ --lookup-select-font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', sans-serif;
33
+ --lookup-select-font-size: 14px;
34
+ --lookup-select-font-size-sm: 12px;
35
+ --lookup-select-font-size-lg: 16px;
36
+ --lookup-select-font-weight: 400;
37
+ --lookup-select-font-weight-medium: 500;
38
+ --lookup-select-font-weight-semibold: 600;
39
+ --lookup-select-line-height: 1.4;
40
+
41
+ /* === SHADOWS === */
42
+ --lookup-select-shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
43
+ --lookup-select-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06);
44
+ --lookup-select-shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
45
+ --lookup-select-shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
46
+
47
+ /* === TRANSITIONS === */
48
+ --lookup-select-transition-duration: 150ms;
49
+ --lookup-select-transition-timing: cubic-bezier(0.4, 0, 0.2, 1);
50
+
51
+ /* === Z-INDEX === */
52
+ --lookup-select-z-index-dropdown: 1000;
53
+ --lookup-select-z-index-modal: 1050;
54
+ --lookup-select-z-index-overlay: 1040;
55
+
56
+ /* === COMPONENT SPECIFIC === */
57
+ /* Trigger */
58
+ --lookup-select-trigger-height: 36px;
59
+ --lookup-select-trigger-padding-x: calc(var(--lookup-select-spacing) * 1.5);
60
+ --lookup-select-trigger-padding-y: var(--lookup-select-spacing);
61
+ --lookup-select-trigger-gap: var(--lookup-select-spacing-sm);
62
+
63
+ /* Modal */
64
+ --lookup-select-modal-width: 600px;
65
+ --lookup-select-modal-max-height: 500px;
66
+ --lookup-select-modal-padding: var(--lookup-select-spacing-xl);
67
+
68
+ /* Grid */
69
+ --lookup-select-grid-row-height: 40px;
70
+ --lookup-select-grid-header-height: 44px;
71
+ --lookup-select-grid-cell-padding-x: var(--lookup-select-spacing-lg);
72
+ --lookup-select-grid-cell-padding-y: var(--lookup-select-spacing);
73
+
74
+ /* Pagination */
75
+ --lookup-select-pagination-button-size: 28px;
76
+ --lookup-select-pagination-gap: var(--lookup-select-spacing-sm);
77
+
78
+ /* Search */
79
+ --lookup-select-search-height: 36px;
80
+ --lookup-select-search-padding-x: var(--lookup-select-spacing-lg);
81
+ }
82
+
83
+ /* === ROOT === */
84
+ .lookup-select {
85
+ position: relative;
86
+ display: inline-block;
87
+ font-family: var(--lookup-select-font-family);
88
+ font-size: var(--lookup-select-font-size);
89
+ font-weight: var(--lookup-select-font-weight);
90
+ line-height: var(--lookup-select-line-height);
91
+ color: var(--lookup-select-color-text);
92
+ }
93
+
94
+ .lookup-select * {
95
+ box-sizing: border-box;
96
+ }
97
+
98
+ .lookup-select:focus-within {
99
+ outline: none;
100
+ }
101
+
102
+ /* === TRIGGER === */
103
+ .lookup-select__trigger {
104
+ display: flex;
105
+ align-items: center;
106
+ justify-content: space-between;
107
+ min-height: var(--lookup-select-trigger-height);
108
+ padding: var(--lookup-select-trigger-padding-y) var(--lookup-select-trigger-padding-x);
109
+ background: var(--lookup-select-color-bg);
110
+ border: var(--lookup-select-border-width) solid var(--lookup-select-color-border);
111
+ border-radius: var(--lookup-select-border-radius);
112
+ cursor: pointer;
113
+ transition: all var(--lookup-select-transition-duration) var(--lookup-select-transition-timing);
114
+ min-width: 200px;
115
+ font-size: var(--lookup-select-font-size);
116
+ font-weight: var(--lookup-select-font-weight);
117
+ line-height: var(--lookup-select-line-height);
118
+ color: var(--lookup-select-color-text);
119
+ box-shadow: var(--lookup-select-shadow-sm);
120
+ }
121
+
122
+ .lookup-select__trigger:hover {
123
+ border-color: var(--lookup-select-color-border-hover);
124
+ background: var(--lookup-select-color-bg-hover);
125
+ box-shadow: var(--lookup-select-shadow);
126
+ }
127
+
128
+ .lookup-select__trigger:focus {
129
+ outline: none;
130
+ border-color: var(--lookup-select-color-border-focus);
131
+ box-shadow: 0 0 0 2px rgba(0, 102, 204, 0.2), var(--lookup-select-shadow);
132
+ }
133
+
134
+ .lookup-select__trigger--open {
135
+ border-color: var(--lookup-select-color-border-focus);
136
+ box-shadow: 0 0 0 2px rgba(0, 102, 204, 0.2), var(--lookup-select-shadow);
137
+ }
138
+
139
+ .lookup-select__trigger--disabled {
140
+ cursor: not-allowed;
141
+ opacity: 0.6;
142
+ background: var(--lookup-select-color-bg-secondary);
143
+ }
144
+
145
+ .lookup-select__trigger--error {
146
+ border-color: var(--lookup-select-color-error);
147
+ }
148
+
149
+ .lookup-select__trigger-content {
150
+ flex: 1;
151
+ display: flex;
152
+ align-items: center;
153
+ gap: var(--lookup-select-trigger-gap);
154
+ min-width: 0; /* Allow text truncation */
155
+ }
156
+
157
+ .lookup-select__trigger-actions {
158
+ display: flex;
159
+ align-items: center;
160
+ gap: var(--lookup-select-spacing-sm);
161
+ flex-shrink: 0;
162
+ }
163
+
164
+ .lookup-select__clear-button {
165
+ display: flex;
166
+ align-items: center;
167
+ justify-content: center;
168
+ width: 24px;
169
+ height: 24px;
170
+ background: none;
171
+ border: none;
172
+ border-radius: 50%;
173
+ color: var(--lookup-select-color-text-secondary);
174
+ cursor: pointer;
175
+ transition: all var(--lookup-select-transition-duration) var(--lookup-select-transition-timing);
176
+ opacity: 0.7;
177
+ padding: 2px;
178
+ }
179
+
180
+ .lookup-select__clear-button:hover {
181
+ background: rgba(0, 0, 0, 0.1);
182
+ opacity: 1;
183
+ color: var(--lookup-select-color-text);
184
+ }
185
+
186
+ .lookup-select__trigger-icon {
187
+ display: flex;
188
+ align-items: center;
189
+ justify-content: center;
190
+ width: 24px;
191
+ height: 24px;
192
+ flex-shrink: 0;
193
+ color: var(--lookup-select-color-text-secondary);
194
+ transition: transform var(--lookup-select-transition-duration) var(--lookup-select-transition-timing);
195
+ }
196
+
197
+ .lookup-select__trigger--open .lookup-select__trigger-icon {
198
+ transform: rotate(180deg);
199
+ }
200
+
201
+ /* Selected items styling */
202
+ .lookup-select__selected-items {
203
+ display: flex;
204
+ align-items: center;
205
+ gap: var(--lookup-select-spacing-sm);
206
+ flex-wrap: wrap;
207
+ min-width: 0;
208
+ }
209
+
210
+ .lookup-select__selected-item {
211
+ display: inline-flex;
212
+ align-items: center;
213
+ background: var(--lookup-select-color-primary);
214
+ color: white;
215
+ padding: 2px var(--lookup-select-spacing-sm);
216
+ border-radius: var(--lookup-select-border-radius-sm);
217
+ font-size: var(--lookup-select-font-size-sm);
218
+ font-weight: var(--lookup-select-font-weight-medium);
219
+ max-width: 120px;
220
+ }
221
+
222
+ .lookup-select__selected-item-text {
223
+ overflow: hidden;
224
+ text-overflow: ellipsis;
225
+ white-space: nowrap;
226
+ }
227
+
228
+ .lookup-select__selected-item--more {
229
+ background: var(--lookup-select-color-text-secondary);
230
+ }
231
+
232
+ .lookup-select__selected-item-remove {
233
+ background: none;
234
+ border: none;
235
+ color: inherit;
236
+ margin-left: var(--lookup-select-spacing-sm);
237
+ cursor: pointer;
238
+ padding: 0;
239
+ font-size: var(--lookup-select-font-size);
240
+ line-height: 1;
241
+ opacity: 0.8;
242
+ }
243
+
244
+ .lookup-select__selected-item-remove:hover {
245
+ opacity: 1;
246
+ }
247
+
248
+ /* === MODAL === */
249
+ .lookup-select__modal-overlay {
250
+ position: fixed;
251
+ top: 0;
252
+ left: 0;
253
+ right: 0;
254
+ bottom: 0;
255
+ background: rgba(0, 0, 0, 0.5);
256
+ display: flex;
257
+ align-items: center;
258
+ justify-content: center;
259
+ z-index: 1000;
260
+ padding: 20px;
261
+ }
262
+
263
+ .lookup-select__modal {
264
+ background: var(--lookup-select-color-bg);
265
+ border-radius: var(--lookup-select-border-radius-lg);
266
+ box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
267
+ max-width: 720px;
268
+ width: 95%;
269
+ max-height: 85vh;
270
+ display: flex;
271
+ flex-direction: column;
272
+ overflow: hidden;
273
+ padding: 24px;
274
+ margin: auto;
275
+ }
276
+
277
+ .lookup-select__modal-header {
278
+ display: flex;
279
+ align-items: center;
280
+ justify-content: space-between;
281
+ padding: 0 0 var(--lookup-select-spacing-lg) 0;
282
+ border-bottom: 1px solid var(--lookup-select-color-border);
283
+ flex-shrink: 0;
284
+ margin-bottom: var(--lookup-select-spacing-lg);
285
+ }
286
+
287
+ .lookup-select__modal-title {
288
+ margin: 0;
289
+ font-size: 18px;
290
+ font-weight: 600;
291
+ }
292
+
293
+ .lookup-select__modal-close {
294
+ background: none;
295
+ border: none;
296
+ font-size: 24px;
297
+ cursor: pointer;
298
+ color: #6b7280;
299
+ padding: 4px;
300
+ border-radius: 4px;
301
+ }
302
+
303
+ .lookup-select__modal-close:hover {
304
+ background: var(--lookup-select-color-hover);
305
+ color: var(--lookup-select-color-text);
306
+ }
307
+
308
+ .lookup-select__modal-body {
309
+ flex: 1;
310
+ overflow: auto;
311
+ display: flex;
312
+ flex-direction: column;
313
+ min-height: 0; /* Important for flex child to be scrollable */
314
+ }
315
+
316
+ /* === SEARCH === */
317
+ .lookup-select__search {
318
+ position: relative;
319
+ padding: 0 0 var(--lookup-select-spacing-lg) 0;
320
+ border-bottom: 1px solid var(--lookup-select-color-border);
321
+ flex-shrink: 0;
322
+ background: var(--lookup-select-color-bg);
323
+ z-index: 10;
324
+ }
325
+
326
+ .lookup-select__search-input {
327
+ width: 100%;
328
+ padding: 12px 16px;
329
+ border: 1px solid var(--lookup-select-color-border);
330
+ border-radius: var(--lookup-select-border-radius);
331
+ font-size: var(--lookup-select-font-size);
332
+ font-family: inherit;
333
+ background: var(--lookup-select-color-bg);
334
+ outline: none;
335
+ transition: border-color var(--lookup-select-transition-duration) var(--lookup-select-transition-timing);
336
+ box-sizing: border-box;
337
+ }
338
+
339
+ .lookup-select__search-input:focus {
340
+ outline: none;
341
+ border-color: var(--lookup-select-color-primary);
342
+ box-shadow: 0 0 0 2px rgba(0, 102, 204, 0.2);
343
+ }
344
+
345
+ .lookup-select__search-icon {
346
+ position: absolute;
347
+ right: calc(var(--lookup-select-spacing) * 3);
348
+ top: 50%;
349
+ transform: translateY(-50%);
350
+ color: #6b7280;
351
+ pointer-events: none;
352
+ }
353
+
354
+ /* === MODAL CONTENT === */
355
+ .lookup-select__modal-content {
356
+ flex: 1;
357
+ overflow: auto;
358
+ padding: calc(var(--lookup-select-spacing) * 2);
359
+ }
360
+
361
+ .lookup-select__grid-placeholder {
362
+ text-align: center;
363
+ color: #6b7280;
364
+ padding: calc(var(--lookup-select-spacing) * 4);
365
+ }
366
+
367
+ /* === MODAL FOOTER === */
368
+ .lookup-select__modal-footer {
369
+ display: flex;
370
+ align-items: center;
371
+ justify-content: space-between;
372
+ padding: var(--lookup-select-spacing-lg) 0 0 0;
373
+ border-top: 1px solid var(--lookup-select-color-border);
374
+ background: var(--lookup-select-color-bg-secondary);
375
+ flex-shrink: 0;
376
+ margin-top: var(--lookup-select-spacing);
377
+ }
378
+
379
+ .lookup-select__selected-count {
380
+ font-size: 13px;
381
+ color: #6b7280;
382
+ font-weight: 500;
383
+ }
384
+
385
+ .lookup-select__modal-actions {
386
+ display: flex;
387
+ gap: var(--lookup-select-spacing);
388
+ }
389
+
390
+ .lookup-select__button {
391
+ padding: var(--lookup-select-spacing) calc(var(--lookup-select-spacing) * 2);
392
+ border-radius: var(--lookup-select-border-radius);
393
+ font-size: var(--lookup-select-font-size);
394
+ font-weight: 500;
395
+ cursor: pointer;
396
+ border: 1px solid transparent;
397
+ transition: all 0.2s ease;
398
+ }
399
+
400
+ .lookup-select__button--secondary {
401
+ background: var(--lookup-select-color-bg);
402
+ color: var(--lookup-select-color-text);
403
+ border-color: var(--lookup-select-color-border);
404
+ }
405
+
406
+ .lookup-select__button--secondary:hover {
407
+ background: var(--lookup-select-color-hover);
408
+ }
409
+
410
+ .lookup-select__button--primary {
411
+ background: var(--lookup-select-color-primary);
412
+ color: white;
413
+ border-color: var(--lookup-select-color-primary);
414
+ }
415
+
416
+ .lookup-select__button--primary:hover:not(:disabled) {
417
+ background: #0052a3;
418
+ border-color: #0052a3;
419
+ }
420
+
421
+ .lookup-select__button--primary:disabled {
422
+ opacity: 0.5;
423
+ cursor: not-allowed;
424
+ }
425
+
426
+ /* === PAGINATION === */
427
+ .lookup-select__pagination {
428
+ display: flex;
429
+ align-items: center;
430
+ justify-content: space-between;
431
+ gap: var(--lookup-select-spacing-lg);
432
+ padding: var(--lookup-select-spacing-lg) 0;
433
+ }
434
+
435
+ .lookup-select__pagination-info {
436
+ font-size: var(--lookup-select-font-size-sm);
437
+ color: var(--lookup-select-color-text-secondary);
438
+ font-weight: var(--lookup-select-font-weight);
439
+ white-space: nowrap;
440
+ }
441
+
442
+ .lookup-select__pagination-controls {
443
+ display: flex;
444
+ align-items: center;
445
+ gap: 2px;
446
+ }
447
+
448
+ .lookup-select__pagination-button {
449
+ display: flex;
450
+ align-items: center;
451
+ justify-content: center;
452
+ width: var(--lookup-select-pagination-button-size);
453
+ height: var(--lookup-select-pagination-button-size);
454
+ background: var(--lookup-select-color-bg);
455
+ border: 1px solid var(--lookup-select-color-border);
456
+ border-radius: var(--lookup-select-border-radius);
457
+ font-size: var(--lookup-select-font-size-sm);
458
+ font-weight: var(--lookup-select-font-weight-medium);
459
+ color: var(--lookup-select-color-text);
460
+ cursor: pointer;
461
+ transition: all var(--lookup-select-transition-duration) var(--lookup-select-transition-timing);
462
+ user-select: none;
463
+ }
464
+
465
+ .lookup-select__pagination-button:hover:not(:disabled) {
466
+ background: var(--lookup-select-color-hover);
467
+ border-color: var(--lookup-select-color-primary);
468
+ color: var(--lookup-select-color-primary);
469
+ }
470
+
471
+ .lookup-select__pagination-button--active {
472
+ background: var(--lookup-select-color-primary);
473
+ border-color: var(--lookup-select-color-primary);
474
+ color: white;
475
+ }
476
+
477
+ .lookup-select__pagination-button--active:hover {
478
+ background: #0052a3;
479
+ border-color: #0052a3;
480
+ }
481
+
482
+ .lookup-select__pagination-button:disabled {
483
+ background: var(--lookup-select-color-bg-secondary);
484
+ border-color: var(--lookup-select-color-border);
485
+ color: var(--lookup-select-color-text-disabled);
486
+ cursor: not-allowed;
487
+ opacity: 0.6;
488
+ }
489
+
490
+ .lookup-select__pagination-dots {
491
+ display: flex;
492
+ align-items: center;
493
+ justify-content: center;
494
+ width: var(--lookup-select-pagination-button-size);
495
+ height: var(--lookup-select-pagination-button-size);
496
+ font-size: var(--lookup-select-font-size-sm);
497
+ color: var(--lookup-select-color-text-secondary);
498
+ user-select: none;
499
+ }
500
+
501
+ /* Responsive pagination - mobile */
502
+ @media (max-width: 480px) {
503
+ .lookup-select__pagination {
504
+ flex-direction: column;
505
+ gap: var(--lookup-select-spacing);
506
+ align-items: stretch;
507
+ }
508
+
509
+ .lookup-select__pagination-info {
510
+ text-align: center;
511
+ order: 2;
512
+ }
513
+
514
+ .lookup-select__pagination-controls {
515
+ justify-content: center;
516
+ order: 1;
517
+ }
518
+ }
519
+
520
+ /* === GRID === */
521
+ .lookup-select__grid {
522
+ flex: 1;
523
+ overflow: auto;
524
+ min-height: 0; /* Important for flex child to be scrollable */
525
+ position: relative;
526
+ }
527
+
528
+ .lookup-select__table {
529
+ width: 100%;
530
+ border-collapse: collapse;
531
+ font-size: var(--lookup-select-font-size);
532
+ }
533
+
534
+ .lookup-select__table-head {
535
+ background: var(--lookup-select-color-bg-secondary);
536
+ border-bottom: 2px solid var(--lookup-select-color-border);
537
+ position: sticky;
538
+ top: 0;
539
+ z-index: 5;
540
+ }
541
+
542
+ .lookup-select__table-header {
543
+ padding: var(--lookup-select-spacing-lg) var(--lookup-select-grid-cell-padding-x);
544
+ text-align: left;
545
+ font-weight: 600;
546
+ color: var(--lookup-select-color-text);
547
+ border-bottom: 1px solid var(--lookup-select-color-border);
548
+ background: var(--lookup-select-color-bg-secondary);
549
+ white-space: nowrap;
550
+ }
551
+
552
+ .lookup-select__table-header--checkbox {
553
+ width: 40px;
554
+ text-align: center;
555
+ }
556
+
557
+ .lookup-select__table-header-content {
558
+ display: flex;
559
+ align-items: center;
560
+ gap: var(--lookup-select-spacing);
561
+ }
562
+
563
+ .lookup-select__sort-button {
564
+ background: none;
565
+ border: none;
566
+ color: #6b7280;
567
+ cursor: pointer;
568
+ padding: 2px;
569
+ border-radius: 2px;
570
+ font-size: 12px;
571
+ }
572
+
573
+ .lookup-select__sort-button:hover {
574
+ background: var(--lookup-select-color-hover);
575
+ color: var(--lookup-select-color-text);
576
+ }
577
+
578
+ .lookup-select__table-row {
579
+ border-bottom: 1px solid #f3f4f6;
580
+ cursor: pointer;
581
+ transition: background-color 0.2s ease;
582
+ }
583
+
584
+ .lookup-select__table-row:hover:not(.lookup-select__table-row--disabled) {
585
+ background: var(--lookup-select-color-hover);
586
+ }
587
+
588
+ .lookup-select__table-row--selected {
589
+ background: rgba(0, 102, 204, 0.1);
590
+ }
591
+
592
+ .lookup-select__table-row--selected:hover {
593
+ background: rgba(0, 102, 204, 0.15);
594
+ }
595
+
596
+ .lookup-select__table-row--disabled {
597
+ opacity: 0.5;
598
+ cursor: not-allowed;
599
+ }
600
+
601
+ .lookup-select__table-row:focus {
602
+ outline: none;
603
+ box-shadow: inset 0 0 0 2px rgba(0, 102, 204, 0.3);
604
+ }
605
+
606
+ .lookup-select__table-cell {
607
+ padding: calc(var(--lookup-select-spacing) * 1.5);
608
+ border-bottom: 1px solid #f3f4f6;
609
+ vertical-align: middle;
610
+ }
611
+
612
+ .lookup-select__table-cell--checkbox {
613
+ width: 40px;
614
+ text-align: center;
615
+ }
616
+
617
+ .lookup-select__checkbox {
618
+ display: flex;
619
+ align-items: center;
620
+ justify-content: center;
621
+ }
622
+
623
+ .lookup-select__checkbox input[type="checkbox"] {
624
+ width: 16px;
625
+ height: 16px;
626
+ cursor: pointer;
627
+ }
628
+
629
+ .lookup-select__checkbox input[type="checkbox"]:disabled {
630
+ cursor: not-allowed;
631
+ }
632
+
633
+ /* === GRID STATES === */
634
+ .lookup-select__grid-state {
635
+ display: flex;
636
+ align-items: center;
637
+ justify-content: center;
638
+ min-height: 200px;
639
+ color: #6b7280;
640
+ }
641
+
642
+ .lookup-select__loading {
643
+ display: flex;
644
+ flex-direction: column;
645
+ align-items: center;
646
+ gap: var(--lookup-select-spacing);
647
+ }
648
+
649
+ .lookup-select__loading-spinner {
650
+ width: 24px;
651
+ height: 24px;
652
+ color: var(--lookup-select-color-primary);
653
+ animation: lookup-select-spin 1s linear infinite;
654
+ }
655
+
656
+ @keyframes lookup-select-spin {
657
+ from {
658
+ transform: rotate(0deg);
659
+ }
660
+ to {
661
+ transform: rotate(360deg);
662
+ }
663
+ }
664
+
665
+ .lookup-select__error {
666
+ text-align: center;
667
+ color: var(--lookup-select-color-error);
668
+ }
669
+
670
+ .lookup-select__empty {
671
+ text-align: center;
672
+ color: var(--lookup-select-color-text-secondary);
673
+ padding: var(--lookup-select-spacing-xl);
674
+ font-style: italic;
675
+ }
676
+
677
+ /* === THEME VARIANTS === */
678
+
679
+ /* Dark Theme */
680
+ .lookup-select--theme-dark {
681
+ --lookup-select-color-primary: #3b82f6;
682
+ --lookup-select-color-primary-hover: #2563eb;
683
+ --lookup-select-color-primary-active: #1d4ed8;
684
+ --lookup-select-color-bg: #1f2937;
685
+ --lookup-select-color-bg-secondary: #374151;
686
+ --lookup-select-color-bg-hover: #374151;
687
+ --lookup-select-color-text: #f9fafb;
688
+ --lookup-select-color-text-secondary: #d1d5db;
689
+ --lookup-select-color-text-muted: #9ca3af;
690
+ --lookup-select-color-border: #4b5563;
691
+ --lookup-select-color-border-focus: var(--lookup-select-color-primary);
692
+ --lookup-select-color-border-hover: #6b7280;
693
+ --lookup-select-color-error: #ef4444;
694
+ --lookup-select-color-success: #10b981;
695
+ --lookup-select-color-warning: #f59e0b;
696
+ }
697
+
698
+ /* Minimal Theme */
699
+ .lookup-select--theme-minimal {
700
+ --lookup-select-color-primary: #000000;
701
+ --lookup-select-color-primary-hover: #1f2937;
702
+ --lookup-select-color-primary-active: #374151;
703
+ --lookup-select-color-bg: #ffffff;
704
+ --lookup-select-color-bg-secondary: #ffffff;
705
+ --lookup-select-color-bg-hover: #f9fafb;
706
+ --lookup-select-color-text: #000000;
707
+ --lookup-select-color-text-secondary: #4b5563;
708
+ --lookup-select-color-text-muted: #9ca3af;
709
+ --lookup-select-color-border: #e5e7eb;
710
+ --lookup-select-color-border-focus: #000000;
711
+ --lookup-select-color-border-hover: #d1d5db;
712
+ --lookup-select-border-radius: 0px;
713
+ --lookup-select-border-radius-sm: 0px;
714
+ --lookup-select-border-radius-lg: 0px;
715
+ --lookup-select-shadow-sm: none;
716
+ --lookup-select-shadow: none;
717
+ --lookup-select-shadow-md: none;
718
+ --lookup-select-shadow-lg: 0 1px 3px 0 rgba(0, 0, 0, 0.1);
719
+ }
720
+
721
+ /* Compact Theme */
722
+ .lookup-select--theme-compact {
723
+ --lookup-select-spacing: 6px;
724
+ --lookup-select-spacing-sm: 3px;
725
+ --lookup-select-spacing-lg: 9px;
726
+ --lookup-select-spacing-xl: 12px;
727
+ --lookup-select-font-size: 13px;
728
+ --lookup-select-font-size-sm: 11px;
729
+ --lookup-select-font-size-lg: 14px;
730
+ --lookup-select-trigger-height: 32px;
731
+ --lookup-select-grid-row-height: 36px;
732
+ --lookup-select-grid-header-height: 40px;
733
+ --lookup-select-modal-padding: var(--lookup-select-spacing-lg);
734
+ --lookup-select-border-radius: 4px;
735
+ --lookup-select-border-radius-sm: 2px;
736
+ --lookup-select-border-radius-lg: 6px;
737
+ }
738
+
739
+ /* Size Variants */
740
+ .lookup-select--size-small {
741
+ --lookup-select-font-size: 12px;
742
+ --lookup-select-trigger-height: 28px;
743
+ --lookup-select-spacing: 6px;
744
+ --lookup-select-grid-row-height: 32px;
745
+ }
746
+
747
+ .lookup-select--size-large {
748
+ --lookup-select-font-size: 16px;
749
+ --lookup-select-trigger-height: 44px;
750
+ --lookup-select-spacing: 12px;
751
+ --lookup-select-grid-row-height: 48px;
752
+ }
753
+
754
+ /* === VIRTUAL GRID === */
755
+ .lookup-select__virtual-grid {
756
+ display: flex;
757
+ flex-direction: column;
758
+ height: 100%;
759
+ }
760
+
761
+ .lookup-select__virtual-container {
762
+ flex: 1;
763
+ overflow: auto;
764
+ position: relative;
765
+ scrollbar-width: thin;
766
+ scrollbar-color: var(--lookup-select-color-border) transparent;
767
+ }
768
+
769
+ .lookup-select__virtual-container::-webkit-scrollbar {
770
+ width: 8px;
771
+ }
772
+
773
+ .lookup-select__virtual-container::-webkit-scrollbar-track {
774
+ background: transparent;
775
+ }
776
+
777
+ .lookup-select__virtual-container::-webkit-scrollbar-thumb {
778
+ background: var(--lookup-select-color-border);
779
+ border-radius: var(--lookup-select-border-radius);
780
+ }
781
+
782
+ .lookup-select__virtual-container::-webkit-scrollbar-thumb:hover {
783
+ background: var(--lookup-select-color-border-hover);
784
+ }
785
+
786
+ .lookup-select__virtual-content {
787
+ position: relative;
788
+ }
789
+
790
+ .lookup-select__virtual-row {
791
+ position: absolute;
792
+ left: 0;
793
+ right: 0;
794
+ cursor: pointer;
795
+ transition: background-color var(--lookup-select-transition-duration) var(--lookup-select-transition-timing);
796
+ }
797
+
798
+ .lookup-select__virtual-row:hover {
799
+ background: var(--lookup-select-color-bg-hover);
800
+ }
801
+
802
+ .lookup-select__virtual-row--selected {
803
+ background: rgba(0, 102, 204, 0.1);
804
+ border-left: 3px solid var(--lookup-select-color-primary);
805
+ }
806
+
807
+ .lookup-select__virtual-row--disabled {
808
+ opacity: 0.6;
809
+ cursor: not-allowed;
810
+ }
811
+
812
+ .lookup-select__virtual-row--disabled:hover {
813
+ background: transparent;
814
+ }
815
+
816
+ .lookup-select__virtual-row .lookup-select__table {
817
+ width: 100%;
818
+ height: 100%;
819
+ border-collapse: collapse;
820
+ }
821
+
822
+ .lookup-select__virtual-row .lookup-select__cell {
823
+ padding: var(--lookup-select-grid-cell-padding-y) var(--lookup-select-grid-cell-padding-x);
824
+ border-bottom: 1px solid var(--lookup-select-color-border);
825
+ vertical-align: middle;
826
+ font-size: var(--lookup-select-font-size);
827
+ line-height: var(--lookup-select-line-height);
828
+ }
829
+
830
+ .lookup-select__virtual-row .lookup-select__cell--checkbox {
831
+ width: 40px;
832
+ text-align: center;
833
+ padding: var(--lookup-select-grid-cell-padding-y) var(--lookup-select-spacing);
834
+ }
835
+
836
+ /* === ACCESSIBILITY === */
837
+ .sr-only {
838
+ position: absolute;
839
+ width: 1px;
840
+ height: 1px;
841
+ padding: 0;
842
+ margin: -1px;
843
+ overflow: hidden;
844
+ clip: rect(0, 0, 0, 0);
845
+ white-space: nowrap;
846
+ border: 0;
847
+ }
848
+
849
+ /* High contrast mode support */
850
+ @media (prefers-contrast: high) {
851
+ .lookup-select {
852
+ --lookup-select-color-primary: #0000FF;
853
+ --lookup-select-color-bg: #FFFFFF;
854
+ --lookup-select-color-text: #000000;
855
+ --lookup-select-color-border: #000000;
856
+ --lookup-select-shadow: none;
857
+ }
858
+ }
859
+
860
+ /* Reduced motion support */
861
+ @media (prefers-reduced-motion: reduce) {
862
+ .lookup-select * {
863
+ animation-duration: 0.01ms !important;
864
+ animation-iteration-count: 1 !important;
865
+ transition-duration: 0.01ms !important;
866
+ }
867
+ }
868
+
869
+ /* Focus visible support */
870
+ .lookup-select *:focus-visible {
871
+ outline: 2px solid var(--lookup-select-color-primary);
872
+ outline-offset: 2px;
873
+ }