@juspay/svelte-ui-components 1.32.0 → 1.33.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/dist/Button/Button.svelte +1 -1
- package/dist/Button/properties.d.ts +1 -1
- package/dist/Input/Input.svelte +1 -1
- package/dist/Input/properties.d.ts +1 -1
- package/dist/Modal/Modal.svelte +2 -8
- package/dist/Modal/properties.d.ts +2 -0
- package/dist/Select/Select.svelte +3 -1
- package/dist/Select/properties.d.ts +3 -0
- package/dist/Toast/Toast.svelte +3 -3
- package/dist/Toast/properties.d.ts +4 -0
- package/package.json +2 -2
|
@@ -26,7 +26,7 @@ function handleButtonClick() {
|
|
|
26
26
|
on:click={handleButtonClick}
|
|
27
27
|
disabled={!(properties.enable && !properties.showLoader)}
|
|
28
28
|
type={properties.type}
|
|
29
|
-
data-pw={properties.
|
|
29
|
+
data-pw={properties.testId}
|
|
30
30
|
>
|
|
31
31
|
{#if properties.showLoader && properties.loaderType === 'Circular'}
|
|
32
32
|
<div class="button-loader"><Loader /></div>
|
package/dist/Input/Input.svelte
CHANGED
package/dist/Modal/Modal.svelte
CHANGED
|
@@ -93,18 +93,12 @@ onDestroy(() => {
|
|
|
93
93
|
</div>
|
|
94
94
|
{/if}
|
|
95
95
|
{#if properties.header.text}
|
|
96
|
-
<div class="header-text">
|
|
96
|
+
<div class="header-text" data-pw={properties.header.testId}>
|
|
97
97
|
{properties.header.text}
|
|
98
98
|
</div>
|
|
99
99
|
{/if}
|
|
100
100
|
{#if properties.header.rightImage}
|
|
101
|
-
<div
|
|
102
|
-
role="button"
|
|
103
|
-
tabindex="0"
|
|
104
|
-
on:click={handleRightImageClick}
|
|
105
|
-
on:keydown
|
|
106
|
-
data-pw={properties.rightImageTestId}
|
|
107
|
-
>
|
|
101
|
+
<div role="button" tabindex="0" on:click={handleRightImageClick} on:keydown data-pw={properties.header.buttonTestId}>
|
|
108
102
|
<img class="header-right-img" src={properties.header.rightImage} alt="" />
|
|
109
103
|
</div>
|
|
110
104
|
{/if}
|
|
@@ -109,7 +109,7 @@ onDestroy(() => {
|
|
|
109
109
|
</script>
|
|
110
110
|
|
|
111
111
|
{#if properties.label !== null && properties.label !== ''}
|
|
112
|
-
<label class="label-container" for={properties.label}>
|
|
112
|
+
<label class="label-container" for={properties.label} data-pw={properties.labelTestId}>
|
|
113
113
|
{properties.label}
|
|
114
114
|
</label>
|
|
115
115
|
{/if}
|
|
@@ -123,6 +123,7 @@ onDestroy(() => {
|
|
|
123
123
|
on:keydown
|
|
124
124
|
role="button"
|
|
125
125
|
tabindex="0"
|
|
126
|
+
data-pw={properties.testId}
|
|
126
127
|
>
|
|
127
128
|
{#if properties.leftIcon !== null}
|
|
128
129
|
<div class="icon-container">
|
|
@@ -190,6 +191,7 @@ onDestroy(() => {
|
|
|
190
191
|
class="item {isSelected(properties.selectedItem, item) ? ' item-selected' : ''}"
|
|
191
192
|
role="button"
|
|
192
193
|
tabindex="0"
|
|
194
|
+
data-pw={`${properties.itemTestId}-${item}`}
|
|
193
195
|
>
|
|
194
196
|
{#if properties.selectMultipleItems}
|
|
195
197
|
<CheckListItem checked={isSelected(properties.selectedItem, item)} text="" />
|
package/dist/Toast/Toast.svelte
CHANGED
|
@@ -77,10 +77,10 @@ onDestroy(() => {
|
|
|
77
77
|
</div>
|
|
78
78
|
{/if}
|
|
79
79
|
|
|
80
|
-
<div class="toast-message">
|
|
80
|
+
<div class="toast-message" data-pw={properties.messageTestId}>
|
|
81
81
|
{properties.message}
|
|
82
82
|
{#if properties.subtext}
|
|
83
|
-
<div class="toast-subtext">{properties.subtext}</div>
|
|
83
|
+
<div class="toast-subtext" data-pw={properties.subTextTestId}>{properties.subtext}</div>
|
|
84
84
|
{/if}
|
|
85
85
|
|
|
86
86
|
{#if $$slots.bottomContent}
|
|
@@ -89,7 +89,7 @@ onDestroy(() => {
|
|
|
89
89
|
</div>
|
|
90
90
|
|
|
91
91
|
{#if properties.rightIcon}
|
|
92
|
-
<div class="close-button" tabindex="0" role="button" on:click={hideToast} on:keypress>
|
|
92
|
+
<div class="close-button" tabindex="0" role="button" on:click={hideToast} on:keypress data-pw={properties.closeIconTestId}>
|
|
93
93
|
<img class="toast-icon" src={properties.rightIcon} alt="close-icon" />
|
|
94
94
|
</div>
|
|
95
95
|
{/if}
|
|
@@ -13,5 +13,9 @@ export type ToastProperties = {
|
|
|
13
13
|
inAnimationDuration?: number;
|
|
14
14
|
outAnimationOffset?: number;
|
|
15
15
|
outAnimationDuration?: number;
|
|
16
|
+
testId?: string;
|
|
17
|
+
messageTestId?: string;
|
|
18
|
+
subTextTestId?: string;
|
|
19
|
+
closeIconTestId?: string;
|
|
16
20
|
};
|
|
17
21
|
export declare const defaultToastProperties: ToastProperties;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@juspay/svelte-ui-components",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.33.0",
|
|
4
4
|
"scripts": {
|
|
5
5
|
"dev": "vite dev --host",
|
|
6
6
|
"build": "vite build && npm run package",
|
|
@@ -36,7 +36,7 @@
|
|
|
36
36
|
"@digitalroute/cz-conventional-changelog-for-jira": "^8.0.1",
|
|
37
37
|
"@playwright/test": "^1.39.0",
|
|
38
38
|
"@sveltejs/adapter-auto": "^2.1.1",
|
|
39
|
-
"@sveltejs/kit": "^
|
|
39
|
+
"@sveltejs/kit": "^2.20.6",
|
|
40
40
|
"@sveltejs/package": "^2.2.2",
|
|
41
41
|
"@typescript-eslint/eslint-plugin": "^6.11.0",
|
|
42
42
|
"@typescript-eslint/parser": "^6.11.0",
|