Releases: globus/static-data-portal
v2.1.0
2.1.0 (2024-11-15)
Features
- Adds "Clear Selected" button to the source file browser. (79058b6)
- Adds "Search All Collections" toggle in the search panel. (79058b6)
- Updates Destination search to hide collections the user does not have Transfer-related permissions on (by default) (#370) (79058b6)
Fixes
v2.0.0
2.0.0 (2024-10-29)
⚠ BREAKING CHANGES
The portal will now store authorization tokens in memory (previously localStorage
) by default. This change underlines our commitment to providing a "secure by default" implementation.
How is In-Memory Storage More Secure?
When using our GitHub Template Repository to create a portal, your portal is automatically configured to deploy to GitHub Pages. Without a custom domain configuration, your application will be deployed to {username}.github.io/{repository-name}
. Due to the same origin access policies of localStorage
this means any application you1 deploy to GitHub pages would have access to items placed in localStorage
by the portal. We believe this default behavior is the less secure option and can lead to unexpected behavior based on your GitHub account usage.
Explaining the Breaking Change
With this new default, the end-user experience around authorization will change to requiring users to authenticate when the portal's browser window is closed. Due to the nature of this change we have flagged this change as a "breaking change", resulting in a major version bump. While we do believe most users should update without making changes to their static.json
file, we have included the ability to opt-in to the previous behavior of storing authorization information in localStorage
. Before enabling this functionality, we recommend being aware of security best practices related to localStorage
, using a custom domain for your portal to better lock down origin access, or having policies in place to avoid unintended access when using the default GitHub Pages domain.
To opt out of this change, a new property in the static.json
has been added to enable localStorage
storage of authorization data (data.attributes.features.useLocalStorage
).
{
"_static": {
"generator": {
"name": "@globus/static-data-portal"
}
},
"data": {
"version": "1.0.0",
"attributes": {
"features": {
"useLocalStorage": true
}
}
}
}
Features
-
localStorage
is only available to applications on the same origin, which includes subdomain; Access is only shared with GitHub Pages applications or sites on the same account, not other GitHub account's deployments. ↩
v1.12.0
v1.11.0
v1.10.2
v1.10.1
v1.10.0
1.10.0 (2024-09-18)
Features
Multiple collections (and paths) can now be configured using the static.json
file.
globus.transfer.collections
can now be configured to an array of TransferCollectionConfiguration
objects.
"globus": {
"transfer": {
"collections": [
{
"collection_id": "543aade1-db97-4a4b-9bdf-0b58e78dfa69"
},
{
"collection_id": "8062693f-f8c2-46be-86d0-de651a974ff3",
"path": "/home/u_odwnwpvxpjhatlzwj4ap3svc3q/My First Folder"
}
]
}
// ...
}
When this property is provided, the user will be presented with a source selector.
globus.transfer.collection_id
can still be used to enforce a single collection/path without the selector.
Fixes
v1.9.0
1.9.0 (2024-08-26)
Features
Fixes
- Address scenarios where post-consent an existing (refreshed) token would be used instead of the result of the token response. (a3a2d03)
- Search: Ensures GCSv5 Endpoints ("nonfunctional" endpoints that do not support transfer) are not displayed in destination collection search results. (#231) (1702e62)
v1.8.0
1.8.0 (2024-08-19)
We're happy to announce the availability of many new features in the data portal – ready for your deployment!
If you have any questions or issues with your portal, feel free to open a GitHub Issue or contact Globus Support at [email protected].
New Features
Custom Content – content
Directory
To simplify adding custom pages or documentation to your data portal, we now support a content
directory that allows you to host arbitrary Markdown files. The generated portal will include these files as pages, resulting in URL-accessible routes hosted at their designated path.
Adding Markdown-based Documentation
The most common use case for the content
directory is hosting documentation for your users.
Custom-Content.mp4
Customizing the Landing Page Using Markdown
Provide a custom index.md
in your content
directory – the portal will then use this as the landing page. This override can be helpful for including customization beyond the properties supported in the static.json
file.
Custom-Landing.mp4
Images and Other Assets
Prior to this release, images referenced in the static.json
file (e.g., attributes.content.image
) were expected to be externally hosted assets. With this update can now place arbitrary images and assets in content/assets
. These files will be hosted similarly to the rest of your custom content and can be referenced using relative paths in the static.json
file and Markdown.
For example, you have uploaded a file at content/assets/globus-site.png
, the file can be referenced in Markdown as ![](/globus-site.png)
.
Advanced Use
To allow you to customize even further, files in the content
directory support MDX (.mdx
).
Using MDX can be a helpful method for incorporating existing UI/UX elements (e.g., buttons) into your Markdown-based content.
In addition to MDX, you can reach for JavaScript (.js(x)
) or TypeScript (.ts(x)
) since, under the hood, the files you provide in content
are synced with our Next.js pages
directory.
Navigation Support
While linking between Markdown files in your Custom Content might be enough for your use case, we've also added support for extending the portal's navigation using the static.json
file.
{
"attributes": {
"navigation": {
"items": [
{ "label": "Example, "to": "/example"},
{ "label": "Source", "href": "https://github.com/globus/template-data-portal" }
]
}
}
}
This structure allows you to include both internal (relative) paths, and external links.
Improvements
- The file browser/Transfer experience has been moved to the
/transfer
route to accommodate custom landing pages. - Improves network request performance and loading states across the application.
- Many UX and UI improvements to the Transfer page.
Auto-generated release notes can be found below.
Features
- adds support for "content" directory (#159) (8a21371)
- Globus Transfer interactions have been moved to the /transfer route. This allows for custom homepages on
/
using aindex.(mdx/tsx)
file. (#204) (c282f81) - Improves network request performance and loading states by implementing a cache layer. (#194) (070ab91)
- support content/assets/* => public/* (2e5945d)
- upgrade to @globus/sdk 3.8.0 and use new Transfer utility methods (#199) (989cc44)
Fixes
content
file overrides for well-known pages (e.g.index.*
,privacy-policy.*
), no longer need to match the generator's extension (#224) (e3754a9)- Adds external link icon to external links in the main navigation and reorders custom links. (34b6915)
- Adds loading states to "Refresh" and "Start Transfer" buttons. (070ab91)
- adds predev script (runs prebuild) (d027fe4)
- adds useLayout hook and improves rendering of pages by sharing a Container (#207) (68bccd8)
- Ensure full hosted base path is used in various image rendering contexts. (#218) (03a3c43)
- Ensure relative links in Markdown use Next.js Link component for rendering. (#206) (34b6915)
- ensure relative paths can be used for images in Markdown (#217) (92ebdf3)
- ensure the /authorization route refreshes tokens (when returning from an authorization_requirements prompt) (#195) (b042a81)
- Improves base Markdown rendering for various elements (#216) (b3e1f30)
- improves the loading states of file browsers (#205) (fe58559)
- Only render "Size" values for files in file browsers. (a89c2d0)
- Throttles the
<CollectionSearch>
requests. (070ab91)