Redesign Share UI to emphasize difference between Original URLs and Snapshot URLs.#8157
Closed
cjcenizal wants to merge 18 commits intoelastic:masterfrom
Closed
Redesign Share UI to emphasize difference between Original URLs and Snapshot URLs.#8157cjcenizal wants to merge 18 commits intoelastic:masterfrom
cjcenizal wants to merge 18 commits intoelastic:masterfrom
Conversation
Kibana currently stores it's entire application state in the URL by rison encoding it and sticking it into a query string parameter, _a for AppState and _g for GlobalState. This has functioned fine for a while, but Internet Explorer's short URL length restriction are starting to become a problem for more and more users. To provide these users with a workaround this adds an advanced config option that will store the state in sessionStorage instead of the URL. This is accomplished by hashing the serialized version of the state, storing a short version of the hash in the URL, and storing the whole serialized state in sessionStorage using the hash + state-type as a key. Since sessionStorage is limited in size, we must clean up old stored states after they become unreachable to the application. This is done using the new `LazyLruStore` class, a wrapper around sessionStorage. This wrapper helps us maintain the list of stored states based on the time they are accessed (On each set the access time is updates). It's cleanup style is configured with it's maxItems, idealClearRatio, and maxIdealClearPercent configurations. The defaults for which should be sufficient. `maxItems`: limits the store to n items, removing the oldest item when the list overflows `idealClearRatio+maxIdealClearPercent`: when `store.setItem(key, value)` throws an error we try to clear space equal to `idealClearRatio * (key+value).length`, but no more space than `totalSize * maxIdealClearPercent`
…age/refactor-pure-functions Refactor state-hashing files into state_hashing and state_storage subdirectories.
…reStateInLocalstorage
…move unused '#remove' method.
…age/refactor-storage-naming Rename HashingStore interface methods for consistency and clarity.
…ateStorageHash module.
…age/simplify-hashing-store-interface Simplify HashingStore interface.
- Replace with HashedItemStore, createStateHash, and isStateHash. - Refactor stubBrowserStorage.
…age/simplify-lazy-lru-store Another approach to managing persisted states.
…reStateInLocalstorage
…ateInLocalstorage
b9eb2be to
331d2ed
Compare
…napshot URLs. - Remove share_object_url. - Remove clipboard npm dependency.
331d2ed to
b188da2
Compare
Contributor
Author
|
I got some design feedback from @alt74 and we updated the UI to look like this: |
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Redesign Share UI to emphasize difference between Original URLs and Snapshot URLs.
Discover
Unsaved
Saved
Short URL
Dashboard
Unsaved
Saved
Short URL
Visualization
Unsaved
Saved
Short URL