gbs-add-block 1.2.0 → 1.2.2
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
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# GBS Building Blocks 2.0 (v1.2.
|
|
1
|
+
# GBS Building Blocks 2.0 (v1.2.2)
|
|
2
2
|
|
|
3
3
|
Latest and upgraded version of GBS building blocks with headless UI and removed dependencies.
|
|
4
4
|
|
|
@@ -6,12 +6,10 @@ Latest and upgraded version of GBS building blocks with headless UI and removed
|
|
|
6
6
|
|
|
7
7
|
For detailed documentation on usage and props, Please visit: [Building Block Documentation v2.0](https://gramprokit.vercel.app)
|
|
8
8
|
|
|
9
|
-
## What's New 🎉 (Ver 1.2.
|
|
9
|
+
## What's New 🎉 (Ver 1.2.2)
|
|
10
10
|
|
|
11
|
-
- Updated Data Grid
|
|
12
11
|
- Style Updates
|
|
13
12
|
- Bug Fix
|
|
14
|
-
- New Documentation Site
|
|
15
13
|
|
|
16
14
|
## Authors
|
|
17
15
|
|
package/package.json
CHANGED
|
@@ -45,15 +45,17 @@ export const Breadcrumb = ({
|
|
|
45
45
|
>
|
|
46
46
|
{segment.label}
|
|
47
47
|
</a>
|
|
48
|
-
|
|
49
|
-
<
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
48
|
+
{!isLast && (
|
|
49
|
+
<span className="mx-2 text-gray-400">
|
|
50
|
+
<Icon
|
|
51
|
+
elements={rightArrow}
|
|
52
|
+
dimensions={{ width: 14, height: 14 }}
|
|
53
|
+
svgClass={
|
|
54
|
+
"stroke-black fill-none dark:stroke-white cursor-pointer"
|
|
55
|
+
}
|
|
56
|
+
/>
|
|
57
|
+
</span>
|
|
58
|
+
)}
|
|
57
59
|
</>
|
|
58
60
|
</li>
|
|
59
61
|
);
|
|
@@ -146,14 +146,10 @@ export const DatePicker = ({
|
|
|
146
146
|
elements={calender}
|
|
147
147
|
svgClass={iconClass["grey-common"]}
|
|
148
148
|
/>
|
|
149
|
-
<span className={!selectedDate ? "text-gray-400 text-sm" : ""}>
|
|
150
|
-
{selectedDate
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
</span>
|
|
154
|
-
) : (
|
|
155
|
-
placeholder
|
|
156
|
-
)}
|
|
149
|
+
<span className={!selectedDate ? "text-gray-400 text-sm" : "text-sm"}>
|
|
150
|
+
{selectedDate
|
|
151
|
+
? selectedDate.toLocaleDateString("en-GB")
|
|
152
|
+
: placeholder}
|
|
157
153
|
</span>
|
|
158
154
|
</button>
|
|
159
155
|
|
|
@@ -175,8 +171,8 @@ export const DatePicker = ({
|
|
|
175
171
|
/>
|
|
176
172
|
|
|
177
173
|
{showDatepicker && !disabled && (
|
|
178
|
-
<div className={popUp["pop-up-style"]}>
|
|
179
|
-
<div className="flex justify-between items-center p-2">
|
|
174
|
+
<div className={popUp["pop-up-style-calender"]}>
|
|
175
|
+
<div className="flex justify-between items-center p-2 text-xs">
|
|
180
176
|
<div className="flex items-center space-x-2">
|
|
181
177
|
<span className="text-md font-semibold">
|
|
182
178
|
{new Date(currentYear, currentMonth).toLocaleString("default", {
|
|
@@ -301,14 +297,17 @@ export const DatePicker = ({
|
|
|
301
297
|
) : (
|
|
302
298
|
<div className="grid grid-cols-7 gap-1 p-2">
|
|
303
299
|
{["Su", "Mo", "Tu", "We", "Th", "Fr", "Sa"].map((day) => (
|
|
304
|
-
<div key={day} className="text-center font-bold text-
|
|
300
|
+
<div key={day} className="text-center font-bold text-xs p-1">
|
|
305
301
|
{day}
|
|
306
302
|
</div>
|
|
307
303
|
))}
|
|
308
304
|
{days.flat().map((day: Date | null, index: number) => {
|
|
309
305
|
if (!day) {
|
|
310
306
|
return (
|
|
311
|
-
<div
|
|
307
|
+
<div
|
|
308
|
+
key={index}
|
|
309
|
+
className="text-center p-1 w-8 h-8 text-xs"
|
|
310
|
+
></div>
|
|
312
311
|
);
|
|
313
312
|
}
|
|
314
313
|
const isDisabled: boolean | undefined =
|
|
@@ -326,7 +325,7 @@ export const DatePicker = ({
|
|
|
326
325
|
key={index}
|
|
327
326
|
onClick={() => !isDisabled && selectDate(day)}
|
|
328
327
|
disabled={isDisabled}
|
|
329
|
-
className={`text-center p-1 w-8 h-8 cursor-pointer rounded-md hover:bg-gray-200 transition duration-150 ease-in-out ${
|
|
328
|
+
className={`text-center text-xs p-1 w-8 h-8 cursor-pointer rounded-md hover:bg-gray-200 transition duration-150 ease-in-out ${
|
|
330
329
|
isSelected
|
|
331
330
|
? "bg-black text-white hover:bg-gray-800 dark:bg-zinc-500"
|
|
332
331
|
: ""
|
|
@@ -342,7 +341,7 @@ export const DatePicker = ({
|
|
|
342
341
|
})}
|
|
343
342
|
</div>
|
|
344
343
|
)}
|
|
345
|
-
<div className="px-2 py-2 flex justify-between mb-8">
|
|
344
|
+
<div className="px-2 py-2 flex justify-between mb-8 text-xs">
|
|
346
345
|
<button
|
|
347
346
|
type="button"
|
|
348
347
|
onClick={goToToday}
|
package/source/globalStyle.ts
CHANGED
|
@@ -6,6 +6,8 @@ export const primary = {
|
|
|
6
6
|
export const popUp = {
|
|
7
7
|
"pop-up-style":
|
|
8
8
|
"w-full absolute overflow-y-auto border border-slate-200 rounded-lg mt-[2px] scrollbar bg-white z-90 scrollbar h-40 dark:bg-black dark:text-white animate-fade-down animate-once animate-duration-200",
|
|
9
|
+
"pop-up-style-calender":
|
|
10
|
+
"w-full absolute overflow-y-auto border border-slate-200 rounded-lg mt-[2px] scrollbar bg-white z-90 scrollbar h-[370px] dark:bg-black dark:text-white animate-fade-down animate-once animate-duration-200",
|
|
9
11
|
};
|
|
10
12
|
|
|
11
13
|
export const iconClass = {
|