Commit graph

15 commits

Author SHA1 Message Date
Matthias Mullie 3e5ad4c83a Replace all direct localStorage interaction by mw.storage
Meanwhile I also updated a few places where a non-string was
passed to/expected from localStorage - this could’ve led to
inconsistencies because localStorage stringifies everything.

And I also removed CP.canSetMediaViewerEnabledOnClick, which
was no longer used anywhere except for a test case.

Bug: T137777
Change-Id: I21ad4ba15ca751bb03e5e2c523d09a45c0444ccf
2017-06-02 11:52:34 +02:00
James D. Forrester 1f7d8ce518 Move default user preference setting to appropriate hook
Bug: T158346
Change-Id: I0edd6da3ba6c4c3f9d80bdba755658c828fee4a1
2017-05-03 17:37:16 +02:00
Geoffrey Mon fc84b8e125 Copy button for attribution text in download dialog
In addition:
* .mw-mmv-reuse-copy => .mw-mmv-dialog-copy because it's not just a
  reuse dialog thing anymore
* Adjust margin between attribution textbox and attribution option
  widget to stay consistent with reuse dialog UI

Bug: T77295
Change-Id: I79abdc1a3c10f0a8c3ecb6f4d444a601595a903f
2016-12-28 11:35:02 -05:00
jenkins-bot 569598cf6a Merge "Add button to select and copy share/embed text to clipboard" 2016-12-26 08:25:38 +00:00
Geoffrey Mon a907339f89 Add button to select and copy share/embed text to clipboard
Clipboard icon adapted from modules/tools/images/pasting.svg from the
ContentTranslation extension.

Also adjusts some margins to better separate embed code box from embed
options

Bug: T77295
Change-Id: Ic7a11eab6ecc767ad4d80b94a7b62578d535d047
2016-12-25 23:59:47 -05:00
Geoffrey Mon aa0b9d81c6 Add alt text attributes to all of the lightbox buttons
* Re-adds next/prev i18n msgs (removed in 532819)
* Adds alt attributes to close, fullscreen, options, next, prev,
  download, and reuse buttons

Bug: T58471
Change-Id: I6ea62124018b1a0ec5110bb500f690cb2368f102
2016-12-13 17:32:16 +00:00
Andrew H 0c3b0a5056 Shorten clickable link text in HTML credit lines
Previously, the clickable text in the generated HTML credit lines
was the entire link to the article. This is shortened to a localized
version of "Link".

Bug: T119686
Change-Id: I708f65a85bfa26c264cdd06a265096027266240c
2016-09-26 17:07:09 -07:00
Gergő Tisza 5c73b4a91e Get rid of version number
Remove useless and misleading version number. It was last updated
in 2013 or so, when MediaViewer was still a beta feature,
and ther was a year of intensive development after that.

Bug: T137477
Change-Id: I4a7cb40852ec55d26260febd446c3d0c4bce9e3f
2016-06-14 07:33:39 +00:00
Gilles Dubuc 53a3d9a379 Make Media Viewer pluggable for the 3D extension
Some of the code encountered accessed mw.config directly,
I cleaned that up by migrating to mmv.Config, which is an
abstraction added to avoid peeking at mw.config directly.

Bug: T132064
Change-Id: I2a95ba703e6c7f46296f8e435bceec769dceebf9
2016-04-15 16:43:45 +02:00
Timo Tijhof 55c7b2d5d5 Message 'multimediaviewer-description-page-popup-text-local' doesn't exist
Bug: T118820
Change-Id: I2909f18195bbaf6101019d731544d0b307a8dd44
2016-03-01 23:01:03 +00:00
Timo Tijhof b493318125 Fix resourceloader message fetch warnings
Remove references to non-existing message keys.
Triggered on every startup module request:

> [resourceloader] WARNING:
> Failed to find multimediaviewer-option-header-viewer ({lang})

* multimediaviewer-option-header-viewer
  (listed in 1853540cd3, but never created)
* multimediaviewer-option-header-filepage
* multimediaviewer-option-desc-viewer
* multimediaviewer-option-desc-filepage
* multimediaviewer-license-cc-by-sa-3.0-migrated
  (CommonsMetaData has this aliased to "cc-by-sa-3.0")
* multimediaviewer-description-page-popup-text-local

Even if JS tries to use them, the messages do not exist. There
are no matches across all Wikimedia Git repositories for these
strings other than extension.json here (no i18n, JS or PHP files).

Bug: T118820
Change-Id: I3585f4862781799d9ba828bdc4170a68c6c36100
2016-02-20 13:42:38 +00:00
Andrew H 1b2866df0d Shorten MediaViewer credit lines
Drop the title and site name. Use a shortened URL
created using the pageID for the curid query parameter.

Add pageID property to mmv.model.Image, using value already
fetched from an existing API request.

Bug: T119686
Depends-On: I0f00b986e6095bdb9b8d6af6fbc5b01995227e02
Change-Id: I9189f00bfbf7639974d66cf1921773855a77a865
2016-01-10 23:44:23 +00:00
Julius Alphonso a9758d21e0 Remove uploader's name from MediaViewer
Only last uploader's name is shows, this turns out to be
more confusing than useful.

Bug: T59308
Change-Id: I7d06b72c581fe8738bffc64b5e36be9983b01ccf
2015-12-29 10:56:08 +05:30
Gergő Tisza 77bfbf61aa Add some error details to bug report
Bug: T111112
Change-Id: I1c3a31ddaefdfec0d86b80891671316741e53b0c
2015-10-26 17:12:34 -07:00
paladox b1b6ba1e1b Add extension.json, empty PHP entry point
Bug: T87943
Change-Id: I1251b22cf6fbeb6d31fdcf1b0662049eaacab18a
2015-10-12 20:08:36 +00:00