mirror of
https://github.com/gristlabs/grist-core.git
synced 2026-03-02 04:09:24 +00:00
(core) Polish upgrade button
Summary: On mobile, clicking the upgrade button will now immediately display the plans modal. The button margins have also been adjusted to be smaller on mobile. Finally, some disabled options related to workspace sharing in the left panel (on personal sites) are now hidden instead. Test Plan: Browser tests. Reviewers: jarek Reviewed By: jarek Differential Revision: https://phab.getgrist.com/D3555
This commit is contained in:
@@ -75,7 +75,9 @@ function createLoadedDocMenu(owner: IDisposableOwner, home: HomeModel) {
|
||||
viewSettings,
|
||||
// Hide the sort and view options when showing the intro.
|
||||
{hideSort: showIntro, hideView: showIntro && page === 'all'},
|
||||
['all', 'workspace'].includes(page) ? upgradeButton.showUpgradeButton() : null,
|
||||
['all', 'workspace'].includes(page)
|
||||
? upgradeButton.showUpgradeButton(css.upgradeButton.cls(''))
|
||||
: null,
|
||||
),
|
||||
|
||||
// Build the pinned docs dom. Builds nothing if the selectedOrg is unloaded.
|
||||
@@ -118,8 +120,6 @@ function createLoadedDocMenu(owner: IDisposableOwner, home: HomeModel) {
|
||||
dom('div',
|
||||
showIntro ? buildHomeIntro(home) : null,
|
||||
buildAllDocsBlock(home, home.workspaces, showIntro, flashDocId, viewSettings),
|
||||
dom.maybe(use => use(isNarrowScreenObs()),
|
||||
() => upgradeButton.showUpgradeCard()),
|
||||
shouldShowTemplates(home, showIntro) ? buildAllDocsTemplates(home, viewSettings) : null,
|
||||
) :
|
||||
(page === 'trash') ?
|
||||
@@ -147,7 +147,7 @@ function createLoadedDocMenu(owner: IDisposableOwner, home: HomeModel) {
|
||||
testId('doclist')
|
||||
),
|
||||
dom.maybe(use => !use(isNarrowScreenObs()) && ['all', 'workspace'].includes(use(home.currentPage)),
|
||||
() => upgradeButton.showUpgradeCard()),
|
||||
() => upgradeButton.showUpgradeCard(css.upgradeCard.cls(''))),
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user