Add URL syntax to set specific UI settings #1060

Open
opened 2012-10-04 09:03:43 +00:00 by j · 8 comments
Owner

[link to edit/play view of an item specific timeline]was:

sometimes it would be nice to be able to link to a specific timeline of an item, like look at the slit-scan timeline at /id/editor...

This could set the timeline for all items or temporarily overwrite it. Both options seem wrong, possibly there is a third.

[link to edit/play view of an item specific timeline]was: sometimes it would be nice to be able to link to a specific timeline of an item, like look at the slit-scan timeline at /id/editor... This could set the timeline for all items or temporarily overwrite it. Both options seem wrong, possibly there is a third.
rlx added the
frontend
label 2012-10-04 09:03:43 +00:00
rlx self-assigned this 2012-10-04 09:03:43 +00:00
rlx added the
enhancement
label 2012-10-04 09:03:43 +00:00
Owner

Should set the timeline UI preference to the given timeline type.

A similar enhancement would be to allow for links to a grid view with frames (as opposed to posters).

But currently, there's no URL pattern for this type of link (which is, basically: set a specific UI setting). Query syntax makes no sense (ui_timelines=slitscan|title=foo), so we would have to introduce a third set of magic keywords (like for view and sort), likely composed of key and value (as the value may not be unique across keys).

Should set the timeline UI preference to the given timeline type. A similar enhancement would be to allow for links to a grid view with frames (as opposed to posters). But currently, there's no URL pattern for this type of link (which is, basically: set a specific UI setting). Query syntax makes no sense (ui_timelines=slitscan|title=foo), so we would have to introduce a third set of magic keywords (like for view and sort), likely composed of key and value (as the value may not be unique across keys).
Owner

The least complicated solution may be to use the hash, i.e. ...#showAnnotations=false,videoTimeline=slitscan

There is potential competition for the hash though (section in about/faq, eventually map place).

The least complicated solution may be to use the hash, i.e. ...#showAnnotations=false,videoTimeline=slitscan There is potential competition for the hash though (section in about/faq, eventually map place).
Owner

This looks good:

#section?key=value&foo.bar=baz

Could be swallowed before invoking the URL controller.

Additionally, we could generate site.org/#?XYZ URLs that link to a complete UI state.

This looks good: #section?key=value&foo.bar=baz Could be swallowed before invoking the URL controller. Additionally, we could generate site.org/#?XYZ URLs that link to a complete UI state.
rlx changed title from link to edit/play view of an item specific timeline to Add URL syntax to set specific UI settings 2012-10-08 22:08:26 +00:00
rlx added the
normal
major
labels 2012-10-08 22:12:29 +00:00
Owner

Also see #1078

Also see #1078
Owner

#?reset may be useful too

#?reset may be useful too
Owner

How do we deal with types?

  • Not at all? showAnnotations = "true"?

  • Automatically coerce to boolean or number? item = 60304?

  • Determine types by parsing pandora.site.user.ui? (hard)

  • Require quotes for string values? #?videoTimeline="slitscan"?

  • Require quotes for string values only if there is an ambiguity?

  • Whitelist + custom code for supported keys? (hard to maintain)

  • Use JSON.parse to allow for ?#listSort=[{"key": "title", "operator": "+"}]?

How do we deal with types? - Not at all? showAnnotations = "true"? - Automatically coerce to boolean or number? item = 60304? - Determine types by parsing pandora.site.user.ui? (hard) - Require quotes for string values? #?videoTimeline="slitscan"? - Require quotes for string values only if there is an ambiguity? - Whitelist + custom code for supported keys? (hard to maintain) - Use JSON.parse to allow for ?#listSort=[{"key": "title", "operator": "+"}]?
Owner

Replying to [rlx]comment:7:

How do we deal with types?

  • Not at all? showAnnotations = "true"?

  • Automatically coerce to boolean or number? item = 60304?

  • Determine types by parsing pandora.site.user.ui? (hard)

  • Require quotes for string values? #?videoTimeline="slitscan"?

  • Require quotes for string values only if there is an ambiguity?

  • Whitelist + custom code for supported keys? (hard to maintain)

  • Use JSON.parse to allow for ?#listSort=[{"key": "title", "operator": "+"}]?

For now: JSON.parse(str), or str if JSON.parse throws.

Replying to [rlx]comment:7: > How do we deal with types? > > - Not at all? showAnnotations = "true"? > > - Automatically coerce to boolean or number? item = 60304? > > - Determine types by parsing pandora.site.user.ui? (hard) > > - Require quotes for string values? #?videoTimeline="slitscan"? > > - Require quotes for string values only if there is an ambiguity? > > - Whitelist + custom code for supported keys? (hard to maintain) > > - Use JSON.parse to allow for ?#listSort=[{"key": "title", "operator": "+"}]? For now: JSON.parse(str), or str if JSON.parse throws.
rlx added this to the 13.02 milestone 2013-05-29 12:57:42 +00:00
Owner

Also see #1474 (can corrupt UI settings via URL).

Also see #1474 (can corrupt UI settings via URL).
rlx modified the milestone from 13.02 to 14.02 2014-02-09 18:43:51 +00:00
Sign in to join this conversation.
No Milestone
No Assignees
2 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: 0x2620/pandora#1060
No description provided.