Skip to content

Commit d04a178

Browse files
authored
Merge branch 'develop' into fix/#2609-Legal-translation-fixes
2 parents 7b85ad4 + fa65726 commit d04a178

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

51 files changed

+1708
-2373
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ Issues and Pull Requests categorized under the PATCH or MINOR Release Milestones
3838

3939
We will aim to deploy on a 1-2 month basis. Here are some dates we’re working towards:
4040

41-
2.11.0 MINOR Release: By December 22, 2023
41+
2.11.0 MINOR Release: By January 16, 2023
4242

4343
[You can read more about Semantic Versioning and the differences between a MINOR and PATCH release](https://semver.org/).
4444

client/common/Button.jsx

Lines changed: 5 additions & 59 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,8 @@ const displays = {
2121
const StyledButton = styled.button`
2222
&&& {
2323
font-weight: bold;
24-
display: flex;
24+
display: ${({ display }) =>
25+
display === displays.inline ? 'inline-flex' : 'flex'};
2526
justify-content: center;
2627
align-items: center;
2728
@@ -107,57 +108,6 @@ const StyledInlineButton = styled.button`
107108
}
108109
`;
109110

110-
const StyledIconButton = styled.button`
111-
&&& {
112-
display: flex;
113-
justify-content: center;
114-
align-items: center;
115-
116-
width: ${remSize(32)}px;
117-
height: ${remSize(32)}px;
118-
text-decoration: none;
119-
120-
color: ${({ kind }) => prop(`Button.${kind}.default.foreground`)};
121-
background-color: ${({ kind }) => prop(`Button.${kind}.hover.background`)};
122-
cursor: pointer;
123-
border: 1px solid transparent;
124-
border-radius: 50%;
125-
padding: ${remSize(8)} ${remSize(25)};
126-
line-height: 1;
127-
128-
&:hover:not(:disabled) {
129-
color: ${({ kind }) => prop(`Button.${kind}.hover.foreground`)};
130-
background-color: ${({ kind }) =>
131-
prop(`Button.${kind}.hover.background`)};
132-
133-
svg * {
134-
fill: ${({ kind }) => prop(`Button.${kind}.hover.foreground`)};
135-
}
136-
}
137-
138-
&:active:not(:disabled) {
139-
color: ${({ kind }) => prop(`Button.${kind}.active.foreground`)};
140-
background-color: ${({ kind }) =>
141-
prop(`Button.${kind}.active.background`)};
142-
143-
svg * {
144-
fill: ${({ kind }) => prop(`Button.${kind}.active.foreground`)};
145-
}
146-
}
147-
148-
&:disabled {
149-
color: ${({ kind }) => prop(`Button.${kind}.disabled.foreground`)};
150-
background-color: ${({ kind }) =>
151-
prop(`Button.${kind}.disabled.background`)};
152-
cursor: not-allowed;
153-
}
154-
155-
> * + * {
156-
margin-left: ${remSize(8)};
157-
}
158-
}
159-
`;
160-
161111
/**
162112
* A Button performs an primary action
163113
*/
@@ -184,12 +134,8 @@ const Button = ({
184134
);
185135
let StyledComponent = StyledButton;
186136

187-
if (display === displays.inline) {
188-
StyledComponent = StyledInlineButton;
189-
}
190-
191137
if (iconOnly) {
192-
StyledComponent = StyledIconButton;
138+
StyledComponent = StyledInlineButton;
193139
}
194140

195141
if (href) {
@@ -265,7 +211,7 @@ Button.propTypes = {
265211
/**
266212
* The display type of the button—inline or block
267213
*/
268-
display: PropTypes.string,
214+
display: PropTypes.oneOf(Object.values(displays)),
269215
/**
270216
* SVG icon to place after child content
271217
*/
@@ -286,7 +232,7 @@ Button.propTypes = {
286232
* Specifying an href will use an <a> to link to the URL
287233
*/
288234
href: PropTypes.string,
289-
/*
235+
/**
290236
* An ARIA Label used for accessibility
291237
*/
292238
'aria-label': PropTypes.string,

client/common/IconButton.jsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ const IconButton = (props) => {
1919
return (
2020
<ButtonWrapper
2121
iconBefore={icon && <Icon />}
22+
iconOnly
2223
display={Button.displays.inline}
2324
focusable="false"
2425
{...otherProps}

client/constants.js

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -90,8 +90,6 @@ export const SHOW_EDITOR_OPTIONS = 'SHOW_EDITOR_OPTIONS';
9090
export const CLOSE_EDITOR_OPTIONS = 'CLOSE_EDITOR_OPTIONS';
9191
export const SHOW_KEYBOARD_SHORTCUT_MODAL = 'SHOW_KEYBOARD_SHORTCUT_MODAL';
9292
export const CLOSE_KEYBOARD_SHORTCUT_MODAL = 'CLOSE_KEYBOARD_SHORTCUT_MODAL';
93-
export const SHOW_FUNDRAISER_MODAL = 'SHOW_FUNDRAISER_MODAL';
94-
export const CLOSE_FUNDRAISER_MODAL = 'CLOSE_FUNDRAISER_MODAL';
9593
export const SHOW_TOAST = 'SHOW_TOAST';
9694
export const HIDE_TOAST = 'HIDE_TOAST';
9795
export const SET_TOAST_TEXT = 'SET_TOAST_TEXT';
@@ -132,8 +130,6 @@ export const CLEAR_PERSISTED_STATE = 'CLEAR_PERSISTED_STATE';
132130

133131
export const HIDE_RUNTIME_ERROR_WARNING = 'HIDE_RUNTIME_ERROR_WARNING';
134132
export const SHOW_RUNTIME_ERROR_WARNING = 'SHOW_RUNTIME_ERROR_WARNING';
135-
export const SET_ASSETS = 'SET_ASSETS';
136-
export const DELETE_ASSET = 'DELETE_ASSET';
137133

138134
export const TOGGLE_DIRECTION = 'TOGGLE_DIRECTION';
139135
export const SET_SORTING = 'SET_SORTING';

client/i18n.js

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,8 @@ import {
1717
zhTW,
1818
uk,
1919
sv,
20-
tr
20+
tr,
21+
enIN
2122
} from 'date-fns/locale';
2223

2324
const fallbackLng = ['en-US'];
@@ -37,12 +38,13 @@ export const availableLanguages = [
3738
'uk-UA',
3839
'zh-CN',
3940
'zh-TW',
40-
'tr'
41+
'tr',
42+
'ur'
4143
];
4244

4345
export function languageKeyToLabel(lang) {
4446
const languageMap = {
45-
be: 'Bengali',
47+
be: 'বাংলা',
4648
de: 'Deutsch',
4749
'en-US': 'English',
4850
'es-419': 'Español',
@@ -56,7 +58,8 @@ export function languageKeyToLabel(lang) {
5658
'uk-UA': 'Українська',
5759
'zh-CN': '简体中文',
5860
'zh-TW': '正體中文',
59-
tr: 'Türkçe'
61+
tr: 'Türkçe',
62+
ur: 'اردو'
6063
};
6164
return languageMap[lang];
6265
}
@@ -77,7 +80,8 @@ export function languageKeyToDateLocale(lang) {
7780
'uk-UA': uk,
7881
'zh-CN': zhCN,
7982
'zh-TW': zhTW,
80-
tr
83+
tr,
84+
ur: enIN
8185
};
8286
return languageMap[lang];
8387
}

0 commit comments

Comments
 (0)