Skip to content
This repository has been archived by the owner on Apr 29, 2022. It is now read-only.

Commit

Permalink
Hide other apps section in MAS build to comply with App Store guideli…
Browse files Browse the repository at this point in the history
…nes (#205)
  • Loading branch information
quanglam2807 authored Jun 30, 2020
1 parent 7567f27 commit 6a73bad
Show file tree
Hide file tree
Showing 3 changed files with 85 additions and 81 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@
"eslint-config-airbnb": "18.2.0",
"eslint-plugin-import": "2.22.0",
"eslint-plugin-jsx-a11y": "6.3.1",
"eslint-plugin-react": "7.20.1",
"eslint-plugin-react": "7.20.2",
"eslint-plugin-react-hooks": "1.7.0",
"glob": "7.1.6",
"greek-utils": "1.2.2",
Expand Down
150 changes: 77 additions & 73 deletions src/components/pages/preferences/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -333,7 +333,7 @@ const Preferences = (props) => {
)}
>
<MenuItem dense onClick={() => requestSetSystemPreference('openAtLogin', 'yes')}>{getLocale('yes')}</MenuItem>
{!process.mas && <MenuItem dense onClick={() => requestSetSystemPreference('openAtLogin', 'yes-hidden')}>{getLocale('yesHidden')}</MenuItem>}
{!window.process.mas && <MenuItem dense onClick={() => requestSetSystemPreference('openAtLogin', 'yes-hidden')}>{getLocale('yesHidden')}</MenuItem>}
<MenuItem dense onClick={() => requestSetSystemPreference('openAtLogin', 'no')}>{getLocale('no2')}</MenuItem>
</EnhancedMenu>
<Divider />
Expand Down Expand Up @@ -370,81 +370,85 @@ const Preferences = (props) => {
</List>
</Paper>

<Typography variant="subtitle2" color="textPrimary" className={classes.paperTitle}>
Atomery Apps
</Typography>
<Paper elevation={0} className={classes.paper}>
<List disablePadding dense>
<ListItem
button
onClick={() => requestOpenInBrowser('https://webcatalogapp.com?utm_source=singlebox_app')}
className={classes.listItemPromotion}
>
<div className={classes.promotionBlock}>
<div className={classes.promotionLeft}>
<img src={webcatalogIconPng} alt="WebCatalog" className={classes.appIcon} />
</div>
<div className={classes.promotionRight}>
<div>
<Typography variant="body1" className={classes.appTitle}>
WebCatalog
</Typography>
<Typography variant="body2" color="textSecondary">
Run Web Apps like Real Apps
</Typography>
{!window.process.mas && (
<>
<Typography variant="subtitle2" color="textPrimary" className={classes.paperTitle}>
Atomery Apps
</Typography>
<Paper elevation={0} className={classes.paper}>
<List disablePadding dense>
<ListItem
button
onClick={() => requestOpenInBrowser('https://webcatalogapp.com?utm_source=singlebox_app')}
className={classes.listItemPromotion}
>
<div className={classes.promotionBlock}>
<div className={classes.promotionLeft}>
<img src={webcatalogIconPng} alt="WebCatalog" className={classes.appIcon} />
</div>
<div className={classes.promotionRight}>
<div>
<Typography variant="body1" className={classes.appTitle}>
WebCatalog
</Typography>
<Typography variant="body2" color="textSecondary">
Run Web Apps like Real Apps
</Typography>
</div>
</div>
</div>
</div>
</div>
<ChevronRightIcon color="action" />
</ListItem>
<Divider />
<ListItem
button
onClick={() => requestOpenInBrowser('https://singleboxapp.com?utm_source=singlebox_app')}
className={classes.listItemPromotion}
>
<div className={classes.promotionBlock}>
<div className={classes.promotionLeft}>
<img src={singleboxIconPng} alt="Singlebox" className={classes.appIcon} />
</div>
<div className={classes.promotionRight}>
<div>
<Typography variant="body1" className={classes.appTitle}>
Singlebox
</Typography>
<Typography variant="body2" color="textSecondary">
All Your Apps in One Single Window
</Typography>
<ChevronRightIcon color="action" />
</ListItem>
<Divider />
<ListItem
button
onClick={() => requestOpenInBrowser('https://singleboxapp.com?utm_source=singlebox_app')}
className={classes.listItemPromotion}
>
<div className={classes.promotionBlock}>
<div className={classes.promotionLeft}>
<img src={singleboxIconPng} alt="Singlebox" className={classes.appIcon} />
</div>
<div className={classes.promotionRight}>
<div>
<Typography variant="body1" className={classes.appTitle}>
Singlebox
</Typography>
<Typography variant="body2" color="textSecondary">
All Your Apps in One Single Window
</Typography>
</div>
</div>
</div>
</div>
</div>
<ChevronRightIcon color="action" />
</ListItem>
<Divider />
<ListItem
button
onClick={() => requestOpenInBrowser('https://translatiumapp.com?utm_source=singlebox_app')}
className={classes.listItemPromotion}
>
<div className={classes.promotionBlock}>
<div className={classes.promotionLeft}>
<img src={translatiumIconPng} alt="Translatium" className={classes.appIcon} />
</div>
<div className={classes.promotionRight}>
<div>
<Typography variant="body1" className={classes.appTitle}>
Translatium
</Typography>
<Typography variant="body2" color="textSecondary">
Translate Any Languages like a Pro
</Typography>
<ChevronRightIcon color="action" />
</ListItem>
<Divider />
<ListItem
button
onClick={() => requestOpenInBrowser('https://translatiumapp.com?utm_source=singlebox_app')}
className={classes.listItemPromotion}
>
<div className={classes.promotionBlock}>
<div className={classes.promotionLeft}>
<img src={translatiumIconPng} alt="Translatium" className={classes.appIcon} />
</div>
<div className={classes.promotionRight}>
<div>
<Typography variant="body1" className={classes.appTitle}>
Translatium
</Typography>
<Typography variant="body2" color="textSecondary">
Translate Any Languages like a Pro
</Typography>
</div>
</div>
</div>
</div>
</div>
<ChevronRightIcon color="action" />
</ListItem>
</List>
</Paper>
<ChevronRightIcon color="action" />
</ListItem>
</List>
</Paper>
</>
)}

<Typography variant="body2" className={classes.paperTitle} />
<Paper elevation={0} className={classes.paper}>
Expand Down
14 changes: 7 additions & 7 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -5609,10 +5609,10 @@ [email protected]:
string.prototype.matchall "^4.0.2"
xregexp "^4.3.0"

[email protected].1:
version "7.20.1"
resolved "https://registry.yarnpkg.com/eslint-plugin-react/-/eslint-plugin-react-7.20.1.tgz#87fcf8d0de225817ba0b2d8f38740733d61ff4ba"
integrity sha512-HitovDhscMmu3uOod3aqZRdKURdXgmlkptEue958gJBmIJO9hvgO4uZyqsJ4+22WqJVP3CsTKfqWSuTlJL6b8w==
[email protected].2:
version "7.20.2"
resolved "https://registry.yarnpkg.com/eslint-plugin-react/-/eslint-plugin-react-7.20.2.tgz#b0d72abcd94c59c842338aa09c800808219ea77d"
integrity sha512-J3BdtsPNbcF/CG9HdyLx7jEtC7tuODODGldkS9P1zU2WMoHPdcsN2enUopgIaec5f9eYhSFI5zQAaWA/dgv2zw==
dependencies:
array-includes "^3.1.1"
array.prototype.flatmap "^1.2.3"
Expand Down Expand Up @@ -13534,9 +13534,9 @@ whatwg-encoding@^1.0.1, whatwg-encoding@^1.0.3, whatwg-encoding@^1.0.5:
iconv-lite "0.4.24"

whatwg-fetch@^3.0.0:
version "3.0.0"
resolved "https://registry.yarnpkg.com/whatwg-fetch/-/whatwg-fetch-3.0.0.tgz#fc804e458cc460009b1a2b966bc8817d2578aefb"
integrity sha512-9GSJUgz1D4MfyKU7KRqwOjXCXTqWdFNvEr7eUBYchQiVc744mqK/MzXPNR2WsPkmkOa4ywfg8C2n8h+13Bey1Q==
version "3.1.0"
resolved "https://registry.yarnpkg.com/whatwg-fetch/-/whatwg-fetch-3.1.0.tgz#49d630cdfa308dba7f2819d49d09364f540dbcc6"
integrity sha512-pgmbsVWKpH9GxLXZmtdowDIqtb/rvPyjjQv3z9wLcmgWKFHilKnZD3ldgrOlwJoPGOUluQsRPWd52yVkPfmI1A==

whatwg-mimetype@^2.1.0, whatwg-mimetype@^2.2.0, whatwg-mimetype@^2.3.0:
version "2.3.0"
Expand Down

0 comments on commit 6a73bad

Please sign in to comment.