@quidgest/ui 0.16.20 → 0.16.21

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.
@@ -7,6 +7,7 @@
7
7
  "QButton",
8
8
  "QButtonGroup",
9
9
  "QCard",
10
+ "QCarousel",
10
11
  "QCheckbox",
11
12
  "QCheckboxLabel",
12
13
  "QCollapsible",
package/dist/ui.css CHANGED
@@ -1070,6 +1070,246 @@ a:focus {
1070
1070
  --card-width: 100%;
1071
1071
  }
1072
1072
 
1073
+ .q-carousel {
1074
+ --q-carousel-height: 360px;
1075
+ position: relative;
1076
+ overflow: hidden;
1077
+ width: 100%;
1078
+ height: var(--q-carousel-height);
1079
+ border-radius: 0.25rem;
1080
+ background-color: var(--q-theme-neutral-light);
1081
+ outline: none;
1082
+ }
1083
+
1084
+ .q-carousel__track {
1085
+ display: flex;
1086
+ width: 100%;
1087
+ height: 100%;
1088
+ will-change: transform;
1089
+ }
1090
+
1091
+ .q-carousel__slide {
1092
+ flex: 0 0 100%;
1093
+ width: 100%;
1094
+ height: 100%;
1095
+ position: relative;
1096
+ cursor: pointer;
1097
+ -webkit-user-select: none;
1098
+ -moz-user-select: none;
1099
+ user-select: none;
1100
+ overflow: hidden;
1101
+ }
1102
+
1103
+ .q-carousel__image {
1104
+ width: 100%;
1105
+ height: 100%;
1106
+ -o-object-fit: cover;
1107
+ object-fit: cover;
1108
+ }
1109
+
1110
+ /* Captions (centered, above indicators) */
1111
+ .q-carousel__caption-global {
1112
+ position: absolute;
1113
+ bottom: 3.5rem;
1114
+ left: 50%;
1115
+ transform: translateX(-50%);
1116
+ text-align: center;
1117
+ color: white;
1118
+ z-index: 20;
1119
+ max-width: 80%;
1120
+ }
1121
+
1122
+ .q-carousel__title {
1123
+ margin: 0 0 0.25rem;
1124
+ font-size: 2rem;
1125
+ font-weight: 600;
1126
+ text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
1127
+ }
1128
+
1129
+ .q-carousel__subtitle {
1130
+ margin: 0;
1131
+ font-size: 1.1rem;
1132
+ opacity: 0.9;
1133
+ text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
1134
+ }
1135
+
1136
+ /* Indicators - horizontal bars */
1137
+ .q-carousel__indicators {
1138
+ position: absolute;
1139
+ bottom: 1rem;
1140
+ left: 50%;
1141
+ transform: translateX(-50%);
1142
+ display: flex;
1143
+ gap: 0.5rem;
1144
+ margin: 0;
1145
+ padding: 0;
1146
+ list-style: none;
1147
+ z-index: 10;
1148
+ }
1149
+
1150
+ .q-carousel__indicator {
1151
+ position: relative; /* Needed for pseudo-element positioning */
1152
+ width: 30px;
1153
+ height: 4px;
1154
+ border-radius: 2px;
1155
+ background-color: rgba(255, 255, 255, 0.5);
1156
+ cursor: pointer;
1157
+ transition: all 0.3s ease;
1158
+ overflow: hidden; /* Hide overflow of the progress bar */
1159
+ }
1160
+
1161
+ .q-carousel__indicator:hover {
1162
+ background-color: rgba(255, 255, 255, 0.8);
1163
+ }
1164
+
1165
+ .q-carousel__indicator--active {
1166
+ background-color: white;
1167
+ box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
1168
+ }
1169
+
1170
+ /* Progress bar for active indicator */
1171
+ .q-carousel__indicator--active::before {
1172
+ content: "";
1173
+ position: absolute;
1174
+ top: 0;
1175
+ left: 0;
1176
+ height: 100%;
1177
+ background-color: rgba(0, 0, 0, 0.2); /* A slightly darker shade to show progress */
1178
+ width: var(--q-carousel-progress-width); /* Controlled by progressValue */
1179
+ transition: width 0.05s linear; /* Smooth, linear transition */
1180
+ will-change: width;
1181
+ }
1182
+
1183
+ /* Controls */
1184
+ .q-carousel__control {
1185
+ position: absolute;
1186
+ top: 50%;
1187
+ transform: translateY(-50%);
1188
+ background: rgba(0, 0, 0, 0.5);
1189
+ border: none;
1190
+ border-radius: 50%;
1191
+ width: 48px;
1192
+ height: 48px;
1193
+ display: flex;
1194
+ align-items: center;
1195
+ justify-content: center;
1196
+ cursor: pointer;
1197
+ z-index: 10;
1198
+ -webkit-backdrop-filter: blur(4px);
1199
+ backdrop-filter: blur(4px);
1200
+ color: white;
1201
+ }
1202
+
1203
+ .q-carousel__control:hover {
1204
+ background: rgba(0, 0, 0, 0.7);
1205
+ }
1206
+
1207
+ .q-carousel__control--prev {
1208
+ left: 1rem;
1209
+ }
1210
+
1211
+ .q-carousel__control--next {
1212
+ right: 1rem;
1213
+ }
1214
+
1215
+ .q-carousel__control-icon.q-icon {
1216
+ width: 24px;
1217
+ height: 24px;
1218
+ }
1219
+
1220
+ .q-carousel__skeleton {
1221
+ position: relative;
1222
+ width: 100%;
1223
+ height: 100%;
1224
+ }
1225
+
1226
+ .q-carousel__skeleton-caption {
1227
+ position: absolute;
1228
+ bottom: 20%;
1229
+ left: 50%;
1230
+ transform: translateX(-50%);
1231
+ display: flex;
1232
+ flex-direction: column;
1233
+ align-items: center;
1234
+ gap: 8px;
1235
+ width: 100%;
1236
+ max-width: 600px;
1237
+ }
1238
+
1239
+ .q-carousel__skeleton-controls {
1240
+ position: absolute;
1241
+ top: 50%;
1242
+ left: 0;
1243
+ right: 0;
1244
+ display: flex;
1245
+ justify-content: space-between;
1246
+ padding: 0 16px;
1247
+ transform: translateY(-50%);
1248
+ }
1249
+
1250
+ .q-carousel__skeleton-caption .q-skeleton-loader__bone,
1251
+ .q-carousel__skeleton-controls .q-skeleton-loader__bone {
1252
+ background-color: var(--q-theme-neutral);
1253
+ }
1254
+
1255
+ .q-carousel__empty-container {
1256
+ display: flex;
1257
+ align-items: center;
1258
+ justify-content: center;
1259
+ width: 100%;
1260
+ height: 100%;
1261
+ }
1262
+
1263
+ .q-carousel__sr-only {
1264
+ position: absolute;
1265
+ width: 1px;
1266
+ height: 1px;
1267
+ padding: 0;
1268
+ margin: -1px;
1269
+ overflow: hidden;
1270
+ clip: rect(0, 0, 0, 0);
1271
+ white-space: nowrap;
1272
+ border: 0;
1273
+ }
1274
+
1275
+ @media (max-width: 768px) {
1276
+ .q-carousel {
1277
+ --q-carousel-height: 300px;
1278
+ }
1279
+ .q-carousel__caption-global {
1280
+ bottom: 3rem;
1281
+ max-width: 90%;
1282
+ }
1283
+ .q-carousel__title {
1284
+ font-size: 1.5rem;
1285
+ }
1286
+ .q-carousel__subtitle {
1287
+ font-size: 1rem;
1288
+ }
1289
+ .q-carousel__control {
1290
+ width: 40px;
1291
+ height: 40px;
1292
+ }
1293
+ .q-carousel__control-icon svg {
1294
+ width: 16px;
1295
+ height: 16px;
1296
+ }
1297
+ .q-carousel__control--prev {
1298
+ left: 0.5rem;
1299
+ }
1300
+ .q-carousel__control--next {
1301
+ right: 0.5rem;
1302
+ }
1303
+ }
1304
+ .q-carousel:focus-visible {
1305
+ outline: 2px solid rgb(var(--q-theme-info-rgb)/50%);
1306
+ }
1307
+
1308
+ .q-carousel__control:focus-visible,
1309
+ .q-carousel__indicator:focus-visible {
1310
+ outline: 2px solid rgb(var(--q-theme-info-rgb)/50%);
1311
+ }
1312
+
1073
1313
  .q-checkbox {
1074
1314
  --box-size: 1.15rem;
1075
1315
  --icon-color: var(--q-theme-on-primary);