Skip to content

Commit 8e19291

Browse files
authored
DYN-5377 tooltip import settings (#20)
* Tooltip for import settings button * bumping version
1 parent daa7c69 commit 8e19291

File tree

3 files changed

+10
-5
lines changed

3 files changed

+10
-5
lines changed

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@dynamods/splash-screen",
3-
"version": "1.0.2",
3+
"version": "1.0.3",
44
"description": "Splash Screen maintained by Dynamo Team@Autodesk",
55
"author": "Autodesk Inc.",
66
"license": "MIT",

src/App.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,7 @@ class App extends React.Component {
6464
launchTitle={this.state.launchTitle}
6565
showScreenAgainLabel={this.state.showScreenAgainLabel}
6666
importSettingsTitle={this.state.importSettingsTitle}
67+
importSettingsTooltipDescription={this.state.importSettingsTooltipDescription}
6768
/> : <Dynamic />
6869
}
6970
</Col>
@@ -84,7 +85,8 @@ class App extends React.Component {
8485
welcomeToDynamoTitle: labels.welcomeToDynamoTitle,
8586
launchTitle: labels.launchTitle,
8687
showScreenAgainLabel: labels.showScreenAgainLabel,
87-
importSettingsTitle: labels.importSettingsTitle
88+
importSettingsTitle: labels.importSettingsTitle,
89+
importSettingsTooltipDescription: labels.importSettingsTooltipDescription
8890
});
8991
}
9092

src/Static.js

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -58,9 +58,9 @@ class Static extends React.Component {
5858
placement={'right'}
5959
overlay={
6060
<Tooltip
61-
hidden={this.state.importStatus !== importStatusEnum.error}
61+
hidden={this.state.importStatus === importStatusEnum.success}
6262
id='button-tooltip'>
63-
{this.state.errorDescription}
63+
{this.state.importStatus == importStatusEnum.error ? this.state.errorDescription : this.props.importSettingsTooltipDescription}
6464
</Tooltip>
6565
}>
6666
<label className='primaryButton px-1'>
@@ -196,14 +196,17 @@ Static.defaultProps = {
196196
launchTitle: 'Launch Dynamo',
197197
showScreenAgainLabel: 'Don\'t show this screen again',
198198
importSettingsTitle: 'Import Settings',
199+
importSettingsTooltipDescription: 'You can import custom settings here, which will overwrite your current settings. If you\'d like to preserve a copy of your current settings, export them before importing new settings. Settings not shown in the Preferences panel will be applied once Dynamo and any host program restarts.'
200+
199201
};
200202

201203
Static.propTypes = {
202204
signInTitle: PropTypes.string,
203205
launchTitle: PropTypes.string,
204206
showScreenAgainLabel: PropTypes.string,
205207
signInStatus: PropTypes.bool,
206-
importSettingsTitle: PropTypes.string
208+
importSettingsTitle: PropTypes.string,
209+
importSettingsTooltipDescription: PropTypes.string
207210
};
208211

209212
export default Static;

0 commit comments

Comments
 (0)