Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Replace checkmark icon for enabling and close icon for disabling #51779

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions src/pages/workspace/categories/WorkspaceCategoriesPage.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -205,7 +205,7 @@ function WorkspaceCategoriesPage({route}: WorkspaceCategoriesPageProps) {
}, {});

options.push({
icon: Expensicons.DocumentSlash,
icon: Expensicons.Close,
text: translate(enabledCategories.length === 1 ? 'workspace.categories.disableCategory' : 'workspace.categories.disableCategories'),
value: CONST.POLICY.BULK_ACTION_TYPES.DISABLE,
onSelected: () => {
Expand All @@ -227,7 +227,7 @@ function WorkspaceCategoriesPage({route}: WorkspaceCategoriesPageProps) {
return acc;
}, {});
options.push({
icon: Expensicons.Document,
icon: Expensicons.Checkmark,
text: translate(disabledCategories.length === 1 ? 'workspace.categories.enableCategory' : 'workspace.categories.enableCategories'),
value: CONST.POLICY.BULK_ACTION_TYPES.ENABLE,
onSelected: () => {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -217,7 +217,7 @@ function PolicyDistanceRatesPage({
options.push({
text: translate('workspace.distanceRates.disableRates', {count: enabledRates.length}),
value: CONST.POLICY.BULK_ACTION_TYPES.DISABLE,
icon: Expensicons.DocumentSlash,
icon: Expensicons.Close,
onSelected: () => (canDisableOrDeleteSelectedRates ? disableRates() : setIsWarningModalVisible(true)),
});
}
Expand All @@ -227,7 +227,7 @@ function PolicyDistanceRatesPage({
options.push({
text: translate('workspace.distanceRates.enableRates', {count: disabledRates.length}),
value: CONST.POLICY.BULK_ACTION_TYPES.ENABLE,
icon: Expensicons.Document,
icon: Expensicons.Checkmark,
onSelected: enableRates,
});
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -190,7 +190,7 @@ function ReportFieldsListValuesPage({
}, []);

options.push({
icon: Expensicons.DocumentSlash,
icon: Expensicons.Close,
text: translate(enabledValues.length === 1 ? 'workspace.reportFields.disableValue' : 'workspace.reportFields.disableValues'),
value: CONST.POLICY.BULK_ACTION_TYPES.DISABLE,
onSelected: () => {
Expand Down Expand Up @@ -222,7 +222,7 @@ function ReportFieldsListValuesPage({
}, []);

options.push({
icon: Expensicons.Document,
icon: Expensicons.Checkmark,
text: translate(disabledValues.length === 1 ? 'workspace.reportFields.enableValue' : 'workspace.reportFields.enableValues'),
value: CONST.POLICY.BULK_ACTION_TYPES.ENABLE,
onSelected: () => {
Expand Down
4 changes: 2 additions & 2 deletions src/pages/workspace/tags/WorkspaceTagsPage.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -253,7 +253,7 @@ function WorkspaceTagsPage({route}: WorkspaceTagsPageProps) {

if (enabledTagCount > 0) {
options.push({
icon: Expensicons.DocumentSlash,
icon: Expensicons.Close,
text: translate(enabledTagCount === 1 ? 'workspace.tags.disableTag' : 'workspace.tags.disableTags'),
value: CONST.POLICY.BULK_ACTION_TYPES.DISABLE,
onSelected: () => {
Expand All @@ -265,7 +265,7 @@ function WorkspaceTagsPage({route}: WorkspaceTagsPageProps) {

if (disabledTagCount > 0) {
options.push({
icon: Expensicons.Document,
icon: Expensicons.Checkmark,
text: translate(disabledTagCount === 1 ? 'workspace.tags.enableTag' : 'workspace.tags.enableTags'),
value: CONST.POLICY.BULK_ACTION_TYPES.ENABLE,
onSelected: () => {
Expand Down
4 changes: 2 additions & 2 deletions src/pages/workspace/tags/WorkspaceViewTagsPage.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -193,7 +193,7 @@ function WorkspaceViewTagsPage({route}: WorkspaceViewTagsProps) {

if (enabledTagCount > 0) {
options.push({
icon: Expensicons.DocumentSlash,
icon: Expensicons.Close,
text: translate(enabledTagCount === 1 ? 'workspace.tags.disableTag' : 'workspace.tags.disableTags'),
value: CONST.POLICY.BULK_ACTION_TYPES.DISABLE,
onSelected: () => {
Expand All @@ -205,7 +205,7 @@ function WorkspaceViewTagsPage({route}: WorkspaceViewTagsProps) {

if (disabledTagCount > 0) {
options.push({
icon: Expensicons.Document,
icon: Expensicons.Checkmark,
text: translate(disabledTagCount === 1 ? 'workspace.tags.enableTag' : 'workspace.tags.enableTags'),
value: CONST.POLICY.BULK_ACTION_TYPES.ENABLE,
onSelected: () => {
Expand Down
4 changes: 2 additions & 2 deletions src/pages/workspace/taxes/WorkspaceTaxesPage.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -207,7 +207,7 @@ function WorkspaceTaxesPage({
// `Disable rates` when at least one enabled rate is selected.
if (selectedTaxesIDs.some((taxID) => !policy?.taxRates?.taxes[taxID]?.isDisabled)) {
options.push({
icon: Expensicons.DocumentSlash,
icon: Expensicons.Close,
text: isMultiple ? translate('workspace.taxes.actions.disableMultiple') : translate('workspace.taxes.actions.disable'),
value: CONST.POLICY.BULK_ACTION_TYPES.DISABLE,
onSelected: () => toggleTaxes(false),
Expand All @@ -217,7 +217,7 @@ function WorkspaceTaxesPage({
// `Enable rates` when at least one disabled rate is selected.
if (selectedTaxesIDs.some((taxID) => policy?.taxRates?.taxes[taxID]?.isDisabled)) {
options.push({
icon: Expensicons.Document,
icon: Expensicons.Checkmark,
text: isMultiple ? translate('workspace.taxes.actions.enableMultiple') : translate('workspace.taxes.actions.enable'),
value: CONST.POLICY.BULK_ACTION_TYPES.ENABLE,
onSelected: () => toggleTaxes(true),
Expand Down
Loading