Data table filter - i18n (add-on)
bazza-ui/data-table-filter-i18nFreeBlock
An add-on for the data table filter component to provide i18n support.
Install it
npx shadcn@latest add https://bazza-ui.com/r/data-table-filter-i18n.jsonSource
1import de from '../locales/de.json'2import en from '../locales/en.json'3import fr from '../locales/fr.json'4import nl from '../locales/nl.json'5import zh_CN from '../locales/zh-CN.json'6import zh_TW from '../locales/zh-TW.json'78export type Locale = 'en' | 'fr' | 'nl' | 'zh_CN' | 'zh_TW' | 'de'910type Translations = Record<string, string>1112const translations: Record<Locale, Translations> = {13 en,14 fr,15 zh_CN,16 zh_TW,17 nl,18 de,19}2021export function t(key: string, locale: Locale): string {22 return translations[locale][key] ?? key23}
What it pulls in
npm packages
Files it writes
More from bazza/ui
All 3 items| Component | Registry | Kind | Access | Installs | Command |
|---|---|---|---|---|---|
| Data table filterdata-table-filter | bazza/ui | Blocks | Free | 1 dep · 22 files | |
| Data table filter - TanStack Table (add-on)data-table-filter-tst | bazza/ui | Blocks | Free | no deps · 2 files |
