You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@superset.apache.org by GitBox <gi...@apache.org> on 2022/08/25 18:13:21 UTC
[GitHub] [superset] AndVK opened a new issue, #21200: [SIP-88] Superset. Translation when changing language
AndVK opened a new issue, #21200:
URL: https://github.com/apache/superset/issues/21200
Hi everyone!
### Motivation
Translation of content into other languages is not complete
### Proposed Change
Add a "t" translation function to the following places in the code:
superset-frontend/src/explore/components/controls/DateFilterControl/DateFilterLabel.tsx:317
superset-frontend/src/explore/components/controls/DateFilterControl/DateFilterLabel.tsx:376
```jsx
317: {validTimeRange && <div>{t(evalResponse)}</div>}
376: {t(actualTimeRange)}
```
superset-frontend/src/explore/controls.jsx:341
```jsx
341: label: t(TIME_FILTER_LABELS.time_range),)
```
superset-frontend/src/components/ReportModal/index.tsx:276
```jsx
276: label={t('Report Name')}
```
superset-frontend/src/components/TableLoader/index.tsx:71
```jsx
71: Header: t(column),
```
superset-frontend/src/components/Select/Select.tsx:726
```jsx
726: <Option {...optProps} key={value} label={t(label)} value={value}>
```
superset-frontend/src/dashboard/components/nativeFilters/FiltersConfigModal/FiltersConfigForm/ProcessFilterConfigForm.tsx:815
superset-frontend/src/dashboard/components/nativeFilters/FiltersConfigModal/FiltersConfigForm/ProcessFilterConfigForm.tsx:820
```jsx
815: label: t(mappedName || name),
816: customLabel: isDisabled ? (
817: <Tooltip
818: title={t('Datasets do not contain a temporal column')}
819: >
820: {t(mappedName || name)}
```
superset-frontend/src/dashboard/components/nativeFilters/FiltersConfigModal/FilterTitlePane.tsx:95
```jsx
95: {t(item.label)}
```
superset-frontend/src/explore/components/ControlPanelsContainer.tsx:392
```jsx
392: tooltip={t('This section contains validation errors')}
```
superset-frontend/src/components/ListView/Filters/DateRange.tsx:65
```jsx
65: <FormLabel>{t(Header as string)}</FormLabel>
```
superset-frontend/src/views/components/LanguagePicker.tsx:79
```jsx
79: <a href={languages[langKey].url}>{t(languages[langKey].name)}</a>
```
superset-frontend/src/views/CRUD/chart/ChartCard.tsx:157
```jsx
157: description={t('Modified %s', moment(chart.changed_on_utc).fromNow())}
```
superset-frontend/src/components/TableSelector/index.tsx:236
```jsx
236: if (forceRefresh) addSuccessToast(t('List updated'));
```
superset-frontend/src/views/CRUD/welcome/Welcome.tsx:282
```jsx
282: <h1 className="welcome-header">{t('Home')}</h1>
```
superset-frontend/src/views/components/MenuRight.tsx:309
```jsx
309: {t(menu.label)}
```
superset-frontend/src/views/CRUD/data/database/DatabaseList.tsx:435
superset-frontend/src/views/CRUD/data/database/DatabaseList.tsx:437
superset-frontend/src/views/CRUD/data/database/DatabaseList.tsx:438
```jsx
435: unfilteredLabel: t('All'),
436: selects: [
437: { label: t('Yes'), value: true },
438: { label: t('No'), value: false },
```
superset-frontend/src/views/CRUD/data/database/DatabaseList.tsx:454
superset-frontend/src/views/CRUD/data/database/DatabaseList.tsx:456
superset-frontend/src/views/CRUD/data/database/DatabaseList.tsx:457
```jsx
454: unfilteredLabel: t('All'),
455: selects: [
456: { label: t('Yes'), value: true },
457: { label: t('No'), value: false },
```
superset-frontend/src/views/CRUD/data/dataset/DatasetList.tsx:503
superset-frontend/src/views/CRUD/data/dataset/DatasetList.tsx:505
superset-frontend/src/views/CRUD/data/dataset/DatasetList.tsx:506
```jsx
503: unfilteredLabel: t('All'),
504: selects: [
505: { label: t('Virtual'), value: false },
506: { label: t('Physical'), value: true },
```
superset-frontend/src/visualizations/FilterBox/FilterBox.jsx:304
```jsx
304: label={t(label)}
```
superset-frontend/src/dashboard/components/gridComponents/new/NewMarkdown.jsx:31
```jsx
31: label={t('Markdown')}
```
superset-frontend/src/dashboard/components/SliceAdder.jsx:73-76
```jsx
72: const KEYS_TO_SORT = {
73: slice_name: t('name'),
74: viz_type: t('viz type'),
75: datasource_name: t('dataset'),
76: changed_on: t('recent'),
77: };
```
superset-frontend/src/views/components/Menu.tsx:235
superset-frontend/src/views/components/Menu.tsx:243
superset-frontend/src/views/components/Menu.tsx:250
superset-frontend/src/views/components/Menu.tsx:261
superset-frontend/src/views/components/Menu.tsx:263
```jsx
235: {t(label)}
243: <a href={url}>{t(label)}</a>
250: title={t(label)}
261: <Link to={child.url || ''}>{t(child.label)}</Link>
263: <a href={child.url}>{t(child.label)}</a>
```
superset-frontend/src/views/components/SubMenu.tsx:262
superset-frontend/src/views/components/SubMenu.tsx:278
superset-frontend/src/views/components/SubMenu.tsx:290
superset-frontend/src/views/components/SubMenu.tsx:305
superset-frontend/src/views/components/SubMenu.tsx:310
superset-frontend/src/views/components/SubMenu.tsx:326
```jsx
262: <Link to={tab.url || ''}>{t(tab.label)}</Link>
278: {t(tab.label)}
290: title={t(link.label)}
305: {t(item.label)}
310: <a href={item.url}>{t(item.label)}</a>
326: {t(String(btn.name))}
```
superset-frontend/src/views/CRUD/data/database/DatabaseModal/ModalHeader.tsx:113
superset-frontend/src/views/CRUD/data/database/DatabaseModal/ModalHeader.tsx:153
```jsx
113: {t(`Your database was successfully connected! Here are some optional
114: settings for your database`)}
153: <h4>{t('Select a database to connect')}</h4>
```
superset-frontend/src/views/CRUD/data/database/DatabaseList.tsx:181
```jsx
181: label: t('Upload CSV file'),
```
superset-frontend/src/views/CRUD/welcome/EmptyState.tsx:92, 125-131
```jsx
124: ? t('SQL query')
125: : t(
126: tableName
127: .split('')
128: .slice(0, tableName.length - 1)
129: .join('')
130: .toLowerCase(),
131: )}
```
And also add the ability to translate when changing the language in the following places:
Translation of granularity parameters
![image](https://user-images.githubusercontent.com/89656461/186733582-e6e380c5-ca44-46f8-941f-a42d9abe030b.png)
Translation of duration values in the "Table" chart
![image](https://user-images.githubusercontent.com/89656461/186733815-4c0e4c16-7264-410b-b056-0d28f6568e74.png)
Translation of the dates of the last activities
![image](https://user-images.githubusercontent.com/89656461/186733950-a0a661c8-8192-4853-add1-25bc9750406e.png)
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
[GitHub] [superset] rusackas commented on issue #21200: [SIP-88] Superset. Translation when changing language
Posted by GitBox <gi...@apache.org>.
rusackas commented on issue #21200:
URL: https://github.com/apache/superset/issues/21200#issuecomment-1332780766
Hi @AndVK - I don't think this necessitates a SIP and a voting process... I think this could simply be submitted as a pull request to the repo. If you're willing to make that contribution, I'd be happy to support you in doing so if needed. You can reach out to me on the Superset Slack workgroup or ask any questions here. Thank you for paying attention to this, it's definitely worth pursuing!
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
[GitHub] [superset] rusackas closed issue #21200: [SIP-88] Superset. Translation when changing language
Posted by GitBox <gi...@apache.org>.
rusackas closed issue #21200: [SIP-88] Superset. Translation when changing language
URL: https://github.com/apache/superset/issues/21200
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org