also looking at this
refactor: finish DataTable :text → {{ }} migration
#121
1 file
+4
-5
| @@ -161,7 +161,7 @@ const columnsJson = JSON.stringify(columns) | ||
| 161 | 161 | @click="toggleSort(column.key)" |
| 162 | 162 | > |
| 163 | 163 | <div class="flex items-center gap-1" x-class="{ 'justify-end': column.align === 'right' }"> |
| 164 | <span :text="column.label"></span> | |
| 164 | <span>{{ column.label }}</span> | |
| 165 | 165 | <svg |
| 166 | 166 | :show="sortKey() === column.key" |
| 167 | 167 | class="w-4 h-4" |
| @@ -188,8 +188,7 @@ const columnsJson = JSON.stringify(columns) | ||
| 188 | 188 | 'text-center': column.align === 'center', |
| 189 | 189 | 'tabular-nums': column.format === 'number' || column.format === 'currency' |
| 190 | 190 | }" |
| 191 | :text="formatValueClient(row[column.key], column.format)" | |
| 192 | ></td> | |
| 191 | >{{ formatValueClient(row[column.key], column.format) }}</td> | |
| 193 | 192 | </div> |
| 194 | 193 | </tr> |
| 195 | 194 | </div> |
| @@ -198,7 +197,7 @@ const columnsJson = JSON.stringify(columns) | ||
| 198 | 197 | |
| 199 | 198 | <div :show="totalPagesComputed() >= 2" class="flex items-center justify-between mt-4 pt-4 border-t border-gray-200"> |
| 200 | 199 | <div class="text-sm text-gray-500"> |
| 201 | Showing <span :text="(currentPage() - 1) * tablePgSize + 1"></span> to <span :text="Math.min(currentPage() * tablePgSize, tableRows.length)"></span> of <span :text="tableRows.length"></span> | |
| 200 | Showing <span>{{ (currentPage() - 1) * tablePgSize + 1 }}</span> to <span>{{ Math.min(currentPage() * tablePgSize, tableRows.length) }}</span> of <span>{{ tableRows.length }}</span> | |
| 202 | 201 | </div> |
| 203 | 202 | <div class="flex items-center gap-2"> |
| 204 | 203 | <button |
| @@ -210,7 +209,7 @@ const columnsJson = JSON.stringify(columns) | ||
| 210 | 209 | <Icon name="chevron-left" size="20" /> |
| 211 | 210 | </button> |
| 212 | 211 | <span class="text-sm text-gray-600"> |
| 213 | Page <span :text="currentPage()"></span> of <span :text="totalPagesComputed()"></span> | |
| 212 | Page <span>{{ currentPage() }}</span> of <span>{{ totalPagesComputed() }}</span> | |
| 214 | 213 | </span> |
| 215 | 214 | <button |
| 216 | 215 | type="button" |