Closed Bug 1168960 Opened 10 years ago Closed 9 years ago

[User Story] Pin Site

Categories

(Firefox OS Graveyard :: Gaia::System::Browser Chrome, defect)

ARM
Gonk (Firefox OS)
defect
Not set
normal

Tracking

(feature-b2g:2.5+)

RESOLVED FIXED
FxOS-S6 (04Sep)
feature-b2g 2.5+

People

(Reporter: benfrancis, Assigned: benfrancis)

References

Details

(Keywords: feature, Whiteboard: [systemsfe])

User Story

As a user I want to pin a web site so that I can re-use it often.

Attachments

(2 files, 1 obsolete file)

As a user I want to pin a web site so that I can re-use it often.
A Pivotal Tracker story has been created for this Bug: https://www.pivotaltracker.com/story/show/95560446
feature-b2g: --- → 2.5+
Attached WIP patch
Assignee: nobody → bfrancis
Target Milestone: --- → FxOS-S5 (21Aug)
Comment on attachment 8647645 [details] [review] [gaia] benfrancis:1168960 > mozilla-b2g:master Hi Alberto, could you take a look at this? This patch changes the existing pin button to pin a site instead of a page (the pin page code will be hooked up to some new UI). If a manifest is provided then it's saved along with the siteObject in the bookmark store. It's currently setting siteObject.icon to be backwards compatible with verticalhome, but hopefully the new homescreen will be smarter about picking the right size icon using IconsHelper.
Attachment #8647645 - Flags: review?(apastor)
Comment on attachment 8647645 [details] [review] [gaia] benfrancis:1168960 > mozilla-b2g:master Flagging Kevin in case he can get to it before Alberto can.
Attachment #8647645 - Flags: review?(kevingrandon)
Thanks Ben. The code looks good (left minor comments on Github), but I have some questions: - Should this bug include the UI for pinning the Site? Right now we still see 'Pin Page' and the preview card on the door hanger. Looks a little bit confusing at the moment. - I'm still not convinced about using the current url (instead of the root host name) when pinning a site. I understand that sites like google.com/maps will pin google.com, but do we have many other cases in which pinning the root host name is a problem? How is different then pinning a site than a page if start_url/scope are not provided (which are most of the cases right now)? That said, this is just out of curiosity. This discussion won't block the r+ at all, obviously. Thanks!
Flags: needinfo?(bfrancis)
Thanks Alberto, (In reply to Alberto Pastor [:albertopq] from comment #7) > - Should this bug include the UI for pinning the Site? Right now we still > see 'Pin Page' and the preview card on the door hanger. Looks a little bit > confusing at the moment. Preview Pin Badge is bug 1168955 which I think Michael has nearly finished. I was going to wait for bug 1168958 to land but with the design changes we don't need that any more which is why it's a bit confused, we're swapping the pin page UI for the pin site UI. At least it's behind a pref. > - I'm still not convinced about using the current url (instead of the root > host name) when pinning a site. I understand that sites like google.com/maps > will pin google.com, but do we have many other cases in which pinning the > root host name is a problem? How is different then pinning a site than a > page if start_url/scope are not provided (which are most of the cases right > now)? That said, this is just out of curiosity. This discussion won't block > the r+ at all, obviously. Yeah this is tricky. Ideally I would like to use the root of the domain, but in the case of domains which are split into multiple sites that would make it impossible to pin those sites separately. The obvious example is Google properties, many of which are subdirectories of google.com but are clearly separate sites. Another tricky example is Evernote where evernote.com/ is their product web page and the web app starts at evernote.com/Home.action so you wouldn't want to use "/" as the start_url of the app. We did a study of application scopes during the standardisation of the Web Manifest which shows you how messy URL spaces can be on the web https://docs.google.com/document/d/1fOsQWOOVuKyqO7cXZoKmxZGQ9FLgLMwmCRw3OEqIKrQ/edit?usp=sharing Many websites even span multiple domains which we don't take into account. The difference between pinning a page and pinning a site is not that you're just pinning a different page. Pinning a site pins the whole URL scope which includes multiple pages, and pins the browser chrome to the status bar to make it behave more like an app (with the redesign we will no longer be pinning the browser chrome for pinned pages, as you suggested). We have to default to using the current page as the start_url if none is provided because otherwise it would be impossible to pin some sites. It's possible we could change this later if we made it possible for the user to pick or edit the start_url, but that isn't part of the MVP.
Flags: needinfo?(bfrancis)
Comment on attachment 8647645 [details] [review] [gaia] benfrancis:1168960 > mozilla-b2g:master Thanks for the explanation, Ben. Let's get this landed!
Attachment #8647645 - Flags: review?(apastor) → review+
Target Milestone: FxOS-S5 (21Aug) → FxOS-S6 (04Sep)
Comment on attachment 8647645 [details] [review] [gaia] benfrancis:1168960 > mozilla-b2g:master Addressed review comments, waiting for the tree to re-open in order to land.
Attachment #8647645 - Flags: review?(kevingrandon)
This didn't land due to tree closures and then bitrotted. I've rebased it but there are some test failures I can't reproduce locally. Still investigating.
Attachment #8656019 - Attachment is obsolete: true
Status: NEW → RESOLVED
Closed: 9 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: