Skip to content

Commit

Permalink
Don't show import/export options for sessions if the feature is not e…
Browse files Browse the repository at this point in the history
…nabled

Related to #98
  • Loading branch information
mastef committed Jun 22, 2020
1 parent cb023eb commit 5c35424
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 34 deletions.
21 changes: 4 additions & 17 deletions lib/TabOptions.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -189,7 +189,7 @@ class TabOptions extends React.Component {
<i>By default: disabled ( experimental feature )</i>
</div>
</div>
<div className="toggle-box">
{this.props.sessionsFeature && <div className="toggle-box">
<div className="toggle-box">
<label className="textlabel" htmlFor="session_export" style={{ whiteSpace: "pre", lineHeight: "2rem" }}>
<h4>Export/Backup Sessions</h4>
Expand All @@ -200,8 +200,8 @@ class TabOptions extends React.Component {
<label onMouseEnter={this.props.exportSessionsText} htmlFor="session_export" style={{ whiteSpace: "pre", lineHeight: "2rem" }} />
</div>
<div className="option-description">Allows you to backup your saved windows to an external file.</div>
</div>
<div className="toggle-box">
</div>}
{this.props.sessionsFeature && <div className="toggle-box">
<div className="toggle-box">
<label className="textlabel" htmlFor="session_import" style={{ whiteSpace: "pre", lineHeight: "2rem" }}>
<h4>Import/Restore Sessions</h4>
Expand All @@ -220,7 +220,7 @@ class TabOptions extends React.Component {
<div className="option-description">
Allows you to restore your backup from an external file. The restored windows will be added to your current saved windows.
</div>
</div>
</div>}
</div>,
<div className="optionsBox">
<h4>Popup icon</h4>
Expand Down Expand Up @@ -325,19 +325,6 @@ class TabOptions extends React.Component {
If you also want to see your incognito tabs in the Tab Manager overview, then enable incognito access for this extension.
</div>
</div>
</div>,
<div className="optionsBox">
<h4>Other shortcuts</h4>
<div className="toggle-box">
<div className="toggle-box">
<a href="#" onClick={this.openIncognitoOptions}>
Allow in Incognito
</a>
</div>
<div className="option-description">
If you also want to see your incognito tabs in the Tab Manager overview, then enable incognito access for this extension.
</div>
</div>
<div className="toggle-box">
<a href="#" onClick={this.openShortcuts}>
Change shortcut key
Expand Down
21 changes: 4 additions & 17 deletions lib/TabOptionsFirefox.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -189,7 +189,7 @@ class TabOptions extends React.Component {
<i>By default: disabled ( experimental feature )</i>
</div>
</div>
<div className="toggle-box">
{this.props.sessionsFeature && <div className="toggle-box">
<div className="toggle-box">
<label className="textlabel" htmlFor="session_export" style={{ whiteSpace: "pre", lineHeight: "2rem" }}>
<h4>Export/Backup Sessions</h4>
Expand All @@ -200,8 +200,8 @@ class TabOptions extends React.Component {
<label onMouseEnter={this.props.exportSessionsText} htmlFor="session_export" style={{ whiteSpace: "pre", lineHeight: "2rem" }} />
</div>
<div className="option-description">Allows you to backup your saved windows to an external file.</div>
</div>
<div className="toggle-box">
</div>}
{this.props.sessionsFeature && <div className="toggle-box">
<div className="toggle-box">
<label className="textlabel" htmlFor="session_import" style={{ whiteSpace: "pre", lineHeight: "2rem" }}>
<h4>Import/Restore Sessions</h4>
Expand All @@ -220,7 +220,7 @@ class TabOptions extends React.Component {
<div className="option-description">
Allows you to restore your backup from an external file. The restored windows will be added to your current saved windows.
</div>
</div>
</div>}
</div>,
<div className="optionsBox">
<h4>Popup icon</h4>
Expand Down Expand Up @@ -303,19 +303,6 @@ class TabOptions extends React.Component {
If you also want to see your private tabs in the Tab Manager overview, then enable private windows access for this extension.
</div>
</div>
</div>,
<div className="optionsBox">
<h4>Other shortcuts</h4>
<div className="toggle-box">
<div className="toggle-box">
<a href="#" onClick={this.openIncognitoOptions}>
Allow in Private Windows
</a>
</div>
<div className="option-description">
If you also want to see your private tabs in the Tab Manager overview, then enable private windows access for this extension.
</div>
</div>
<div className="toggle-box">
<a href="#" onClick={this.openShortcuts}>
Change shortcut key
Expand Down

0 comments on commit 5c35424

Please sign in to comment.