-
Notifications
You must be signed in to change notification settings - Fork 17
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add a new feature for 3d basemaps pop up display
- Loading branch information
1 parent
9f783c8
commit a8a0e35
Showing
8 changed files
with
108 additions
and
75 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
This file was deleted.
Oops, something went wrong.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
import { Component, ReactNode } from 'react'; | ||
|
||
import { Config } from '../config.js'; | ||
import { WindowUrl } from '../url.js'; | ||
import { FeatureUpdates } from './feature.updates.js'; | ||
|
||
const baseUrl = WindowUrl.baseUrl(); | ||
|
||
/** | ||
* Please updated the following settings and descriptions for new features pop up | ||
*/ | ||
const bigImage = new URL('assets/Lg+3D+Maps+splash.gif', baseUrl).href; // Large gif file location | ||
const smallImage = new URL('assets/Sml+3D+map+splash.gif', baseUrl).href; // Small gif file location | ||
const closingDate = new Date('2024-10-30'); // End date for pop up screen | ||
const dismissedKey = `DISMISSED_MODALS_LINZ_Basemaps_3D_Map`; // Optional to set as Config.Version to disable Modal as default | ||
const recentUpdates = { | ||
children: ( | ||
<> | ||
<h5 className="RecentUpdatesHeading">Basemaps are now viewable in 3D!</h5> | ||
<p> | ||
To activate this function, click the mountains icon on the left-hand side then hold right-click to change your | ||
viewpoint. | ||
</p> | ||
<p>The new Labels button can also be toggled to show places names.</p> | ||
</> | ||
), | ||
bigImage, | ||
smallImage, | ||
}; | ||
|
||
export class NewFeature extends Component { | ||
enabled = new Date() <= closingDate; | ||
|
||
override render(): ReactNode { | ||
return ( | ||
<FeatureUpdates | ||
id={dismissedKey} | ||
header="What's new" | ||
releaseVersion={Config.Version} | ||
bigImage={recentUpdates.bigImage} | ||
smallImage={recentUpdates.smallImage} | ||
enabled={this.enabled} | ||
> | ||
{recentUpdates.children} | ||
</FeatureUpdates> | ||
); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters