Skip to content

Commit f44407b

Browse files
committed
feat: add title attributes to buttons
1 parent 4853c15 commit f44407b

6 files changed

Lines changed: 20 additions & 2 deletions

File tree

src/components/Cards/product-card.tsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -73,6 +73,7 @@ export const ProductCard: React.FC<ProductCardProps> = ({
7373
<Button
7474
className="bg-blue-400 hover:bg-blue-500 dark:bg-blue-600 dark:hover:bg-blue-700 text-white text-sm px-6 py-2.5 rounded-full font-medium transition-colors duration-200 shadow-sm hover:shadow-md cursor-pointer"
7575
onClick={handleDemoButtonClick}
76+
title="View Demo"
7677
>
7778
Demo
7879
</Button>

src/pages/Home.tsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,7 @@ export const Home = () => {
5353
<a
5454
href="#demos"
5555
className="inline-block px-8 py-3 bg-blue-600 hover:bg-blue-700 text-white font-semibold rounded-lg shadow transition-all text-lg"
56+
title="Scroll to demos section"
5657
>
5758
View Demos
5859
</a>

src/pages/demo-list/mifosx.tsx

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,7 @@ export default function MifosXDemos() {
5858
<Button
5959
className="bg-blue-500 text-white px-3 py-1 rounded text-sm hover:bg-blue-600 cursor-pointer"
6060
onClick={() => NavigateToDemo(id, demoName)}
61+
title="Start this demo"
6162
>
6263
Start Demo
6364
</Button>
@@ -155,6 +156,7 @@ export default function MifosXDemos() {
155156
onClick={() => table.setPageIndex(0)}
156157
disabled={!table.getCanPreviousPage()}
157158
className="p-2 disabled:opacity-50 disabled:cursor-not-allowed"
159+
title="First page"
158160
>
159161
<ChevronsLeft className="h-4 w-4" />
160162
</Button>
@@ -165,6 +167,7 @@ export default function MifosXDemos() {
165167
onClick={() => table.previousPage()}
166168
disabled={!table.getCanPreviousPage()}
167169
className="p-2 disabled:opacity-50 disabled:cursor-not-allowed"
170+
title="Previous page"
168171
>
169172
<ChevronLeft className="h-4 w-4" />
170173
</Button>
@@ -175,6 +178,7 @@ export default function MifosXDemos() {
175178
onClick={() => table.nextPage()}
176179
disabled={!table.getCanNextPage()}
177180
className="p-2 disabled:opacity-50 disabled:cursor-not-allowed"
181+
title="Next page"
178182
>
179183
<ChevronRight className="h-4 w-4" />
180184
</Button>
@@ -185,6 +189,7 @@ export default function MifosXDemos() {
185189
onClick={() => table.setPageIndex(table.getPageCount() - 1)}
186190
disabled={!table.getCanNextPage()}
187191
className="p-2 disabled:opacity-50 disabled:cursor-not-allowed"
192+
title="Last page"
188193
>
189194
<ChevronsRight className="h-4 w-4" />
190195
</Button>

src/pages/demo-list/phee.tsx

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ export default function PheeDemos() {
3939
id: 'action',
4040
header: '',
4141
cell: () => (
42-
<Button className="bg-blue-500 text-white px-3 py-1 rounded text-sm hover:bg-blue-600 cursor-pointer">
42+
<Button className="bg-blue-500 text-white px-3 py-1 rounded text-sm hover:bg-blue-600 cursor-pointer" title="Start this demo">
4343
Start Demo
4444
</Button>
4545
),
@@ -129,6 +129,7 @@ export default function PheeDemos() {
129129
onClick={() => table.setPageIndex(0)}
130130
disabled={!table.getCanPreviousPage()}
131131
className="p-2 disabled:opacity-50 disabled:cursor-not-allowed"
132+
title="First page"
132133
>
133134
<ChevronsLeft className="h-4 w-4" />
134135
</Button>
@@ -139,6 +140,7 @@ export default function PheeDemos() {
139140
onClick={() => table.previousPage()}
140141
disabled={!table.getCanPreviousPage()}
141142
className="p-2 disabled:opacity-50 disabled:cursor-not-allowed"
143+
title="Previous page"
142144
>
143145
<ChevronLeft className="h-4 w-4" />
144146
</Button>
@@ -149,6 +151,7 @@ export default function PheeDemos() {
149151
onClick={() => table.nextPage()}
150152
disabled={!table.getCanNextPage()}
151153
className="p-2 disabled:opacity-50 disabled:cursor-not-allowed"
154+
title="Next page"
152155
>
153156
<ChevronRight className="h-4 w-4" />
154157
</Button>
@@ -159,6 +162,7 @@ export default function PheeDemos() {
159162
onClick={() => table.setPageIndex(table.getPageCount() - 1)}
160163
disabled={!table.getCanNextPage()}
161164
className="p-2 disabled:opacity-50 disabled:cursor-not-allowed"
165+
title="Last page"
162166
>
163167
<ChevronsRight className="h-4 w-4" />
164168
</Button>

src/pages/demo-list/vnext.tsx

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ export default function MifosXDemos() {
3939
id: 'action',
4040
header: '',
4141
cell: () => (
42-
<Button className="bg-blue-500 text-white px-3 py-1 rounded text-sm hover:bg-blue-600 cursor-pointer">
42+
<Button className="bg-blue-500 text-white px-3 py-1 rounded text-sm hover:bg-blue-600 cursor-pointer" title="Start this demo">
4343
Start Demo
4444
</Button>
4545
),
@@ -129,6 +129,7 @@ export default function MifosXDemos() {
129129
onClick={() => table.setPageIndex(0)}
130130
disabled={!table.getCanPreviousPage()}
131131
className="p-2 disabled:opacity-50 disabled:cursor-not-allowed"
132+
title="First page"
132133
>
133134
<ChevronsLeft className="h-4 w-4" />
134135
</Button>
@@ -139,6 +140,7 @@ export default function MifosXDemos() {
139140
onClick={() => table.previousPage()}
140141
disabled={!table.getCanPreviousPage()}
141142
className="p-2 disabled:opacity-50 disabled:cursor-not-allowed"
143+
title="Previous page"
142144
>
143145
<ChevronLeft className="h-4 w-4" />
144146
</Button>
@@ -149,6 +151,7 @@ export default function MifosXDemos() {
149151
onClick={() => table.nextPage()}
150152
disabled={!table.getCanNextPage()}
151153
className="p-2 disabled:opacity-50 disabled:cursor-not-allowed"
154+
title="Next page"
152155
>
153156
<ChevronRight className="h-4 w-4" />
154157
</Button>
@@ -159,6 +162,7 @@ export default function MifosXDemos() {
159162
onClick={() => table.setPageIndex(table.getPageCount() - 1)}
160163
disabled={!table.getCanNextPage()}
161164
className="p-2 disabled:opacity-50 disabled:cursor-not-allowed"
165+
title="Last page"
162166
>
163167
<ChevronsRight className="h-4 w-4" />
164168
</Button>

src/pages/demo/demo-page.tsx

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -116,6 +116,7 @@ export const DemoPage = () => {
116116
onClick={handlePrevious}
117117
disabled={currentStep === 0}
118118
className="flex items-center gap-2 px-4 py-2 text-gray-600 bg-gray-100 rounded-lg hover:bg-gray-200 disabled:opacity-50 disabled:cursor-not-allowed transition-colors cursor-pointer"
119+
title="Go to previous step"
119120
>
120121
<ChevronLeft size={16} />
121122
Previous
@@ -124,6 +125,7 @@ export const DemoPage = () => {
124125
onClick={handleNext}
125126
disabled={currentStep === SampleDemoJsonFile.steps.length - 1}
126127
className="flex items-center gap-2 px-4 py-2 text-white bg-blue-600 rounded-lg hover:bg-blue-700 dark:bg-blue-500 disabled:opacity-50 disabled:cursor-not-allowed transition-colors cursor-pointer"
128+
title="Go to next step"
127129
>
128130
Next
129131
<ChevronRight size={16} />
@@ -143,6 +145,7 @@ export const DemoPage = () => {
143145
? 'bg-blue-100 border-blue-300 text-blue-800 dark:text-gray-600'
144146
: 'bg-gray-50 border-gray-200 text-gray-700 hover:bg-gray-100 dark:bg-gray-800 dark:border-gray-800 dark:hover:bg-gray-900 dark:text-gray-300'
145147
}`}
148+
title={`Go to step: ${step.title}`}
146149
>
147150
<div className="flex items-center gap-3">
148151
<div

0 commit comments

Comments
 (0)