Commit Graph

1244 Commits

Author SHA1 Message Date
Amire80 119f3565f1 Pass the event to ULS core select()
Follow up to #305.
2018-03-26 11:41:54 +03:00
Niklas Laxström b9d400d167 Merge pull request #308 from amire80/ulsPurpose-doc
Update options defaults and documentation
2018-03-21 11:46:04 +02:00
Amire80 99c979edcf Update options defaults and documentation
* Add ulsPurpose to README
* Add default undefined for noResultsTemplate
* Reorder options in the README according to defaults in jquery.uls.core.js
2018-03-21 11:04:43 +02:00
translatewiki.net 862f0483dd Localisation updates from https://translatewiki.net. 2018-03-19 21:02:49 +01:00
Kunal Mehta 515d52793d Update CREDITS (#304) 2018-03-16 14:30:16 +05:30
Niklas Laxström 798e200b56 Merge pull request #305 from amire80/T189582
Pass the event object when calling the click handler
2018-03-15 18:15:50 +02:00
Niklas Laxström 5ac63fc2f1 Merge pull request #307 from amire80/noResults-param
Update the argument for noResults in lcd
2018-03-15 17:39:52 +02:00
Amire80 1120ab276c Update the argument for noResults in lcd
Follow up to #306.
2018-03-15 17:05:01 +02:00
Niklas Laxström ce33de0b9b Merge pull request #306 from amire80/ulsPurposeObject
Send a data object in $.trigger
2018-03-15 16:00:16 +02:00
Amire80 970d073efa Send a data object in $.trigger
There was a mistake in #299: the $.trigger() must take only one argument
for extraParameters. Sending another parameter causes NULL to be logged in
EventLogging for ulsPurpose.
2018-03-15 11:57:02 +02:00
Amire80 f11634e6d3 Pass the event object when calling the click handler
This will allow distinguishing Click and Ctrl/Command-Click.
See downstream bug https://phabricator.wikimedia.org/T189582
2018-03-13 14:34:11 +02:00
translatewiki.net 9019b7742f Localisation updates from https://translatewiki.net. 2018-03-12 09:05:15 +01:00
Kartik Mistry 60ad4af102 Add /vendor to .gitignore (#300) 2018-03-06 11:38:13 +05:30
Niklas Laxström c9c2056d04 Update language-data to 9a506b9 2018-03-05 18:56:02 +05:30
Niklas Laxström 4151ab4a8e Merge pull request #299 from amire80/ulsPurpose
Allow identifying the context of the different ULS panels within one app
2018-03-05 15:24:47 +02:00
Niklas Laxström 438c59cc65 fetch-language-data.sh: Improve and made CWD-independent 2018-03-05 18:25:57 +05:30
Amire80 00ff49e190 Convert ulsPurpose from a data attribute to an languagefilter option 2018-03-05 12:58:00 +02:00
Niklas Laxström 3707da24e0 Merge pull request #301 from kartikm/unbreak-npm-install
Update package.json
2018-03-05 11:48:45 +02:00
Kartik Mistry 43191334ef Update package.json
This will unbreak `npm install`.
2018-03-05 13:54:58 +05:30
Amire80 ddb691a918 Allow identifying the context of the different ULS panels within one app
Add the ulsPurpose option. Empty string by default.

This is useful for web application that use ULS in several different context,
and need to distinguish what was the purpose of the particular ULS panel.

An example of usage can be found at
https://phabricator.wikimedia.org/T179402
2018-03-04 23:01:35 +02:00
translatewiki.net 2d98203aab Localisation updates from https://translatewiki.net. 2018-02-22 12:15:19 +01:00
translatewiki.net 3a28d9a6af Localisation updates from https://translatewiki.net. 2018-02-19 09:10:05 +01:00
Niklas Laxström 8c32f060a1 Merge pull request #298 from santhoshtr/no-results-i18n
i18n for the noResultsTemplate
2018-02-16 09:55:31 +02:00
Santhosh Thottingal 1f900843fe i18n for the noResultsTemplate
See https://phabricator.wikimedia.org/T187390
2018-02-16 09:34:54 +05:30
Pl217 4cb4fe2370 Merge pull request #275 from wikimedia/srpski
Fix "srpski" not finding results in Wikipedia compact links
2018-02-08 15:52:03 +01:00
Pl217 e764c58685 Merge pull request #297 from santhoshtr/array-indexof
Use Array.prototype.indexOf instead of $.inArray
2018-02-08 15:03:07 +01:00
Niklas Laxström eccd0e1945 Change code structure a bit per code review comments 2018-02-08 15:26:15 +02:00
Santhosh Thottingal c2eb7a7850 Use Array.prototype.indexOf instead of $.inArray
All our supported browsers now have this ES5 method.
2018-02-08 17:23:12 +05:30
translatewiki.net 9f9327a96a Localisation updates from https://translatewiki.net. 2018-02-08 10:02:07 +01:00
Niklas Laxström 0352b3df0d Fix to avoid displaying duplicate results caused by redirects 2018-02-07 15:24:15 +02:00
Pl217 819b3b0414 Make ULS responsive
* Make ULS responsive
* Depend on both screen size and number of languages when calculating
ULS menu width.
* Introduce resize listener to responsively recreate ULS when screen
size changes.
2018-02-07 17:30:52 +05:30
Niklas Laxström 9fba3ab728 Fix my broken merge conflict result 2018-02-06 16:41:26 +02:00
Niklas Laxström 2b1cc8678f Merge branch 'master' into srpski 2018-02-06 16:31:46 +02:00
Pl217 54a466ee52 Merge pull request #283 from santhoshtr/keydown-simplify
Simplify key press event handlers
2018-02-06 11:19:45 +01:00
Pl217 9a98bbe561 Merge pull request #294 from santhoshtr/icon-color
Change the language icon color to gray and optimize
2018-02-06 00:22:55 +01:00
Santhosh Thottingal d3921afeac Change the language icon color to gray and optimize
Changed the color to #54595d
2018-02-05 14:49:51 +05:30
Santhosh Thottingal 3161b34b2b language-data update: Add Western Armenian to known languages 2018-02-02 11:55:54 +05:30
Niklas Laxström bb8b48aa38 Stop rendering languages twice on initial display
The resultHandler is responsible for updating the `LanguageCategoryDisplay`, so we should not call `render` separately in `search` when there is no search query.

https://phabricator.wikimedia.org/T185086
2018-01-31 16:52:23 +05:30
Niklas Laxström 104bf1c026 Merge pull request #293 from santhoshtr/no-results-styling
Style adjustments for no-results
2018-01-30 12:25:42 +02:00
Kartik Mistry 4b63f4337f package.json : maintenance updates
* Update minimum node.js engine to 6.11.1, stable LTS.
* http -> https
2018-01-30 02:19:40 -08:00
Santhosh Thottingal 081310b45e Style adjustments for no-results
* 20px spacing above and below the "No results found" message.
* 12px spacing above and below the search indications ("You can search by...")
* Adjusting the text color to use Base20 (#54595D)
* Adjust the background to use the same background color as the area above it (#FCFCFC).
* Add a top border in Base80 (#EAECF0) to separate both areas.

See https://phabricator.wikimedia.org/T175235
2018-01-30 12:52:47 +05:30
translatewiki.net 1e13a60eb3 Localisation updates from https://translatewiki.net. 2018-01-18 08:41:00 +01:00
Santhosh Thottingal d122f371e3 Update documentation for no-results template (#289) 2018-01-16 16:10:53 +02:00
Pl217 4545872983 Use unidirection language icon
* Use single language icon for both LTR and RTL.
* Reduce padding between icon and autonym language name.
2018-01-16 17:39:32 +05:30
Niklas Laxström d349937772 Do not group search results by region
* Documentation updates
* Do not group search results by region
* Disable grouping by script when region grouping is disabled
* Add docs, clarify names per code review
* Fix bool -> boolean for consistency
2018-01-16 17:04:29 +05:30
Pl217 fd41bbe5e1 - Replace ULS trigger icon with monochromatic one.
- Reduce left padding between icon and language autonym name.

Phab ID: T175769
2018-01-12 19:20:11 +01:00
Santhosh Thottingal 2aa43148bb Custom no-results message support (#286)
* Custom no-results message support
* Refactoring and clean up for LanguageCategoryDisplay class
* Document the options for LanguageCategoryDisplay class
* Reduce the spreading of no results handler code
* Add an option to accept no results template
* Remove unwanted, unused constructor too
* Use CSS to hide or show the no-results view
* Remove the unwanted noresults method in jquery.uls.core, directly
  call the same method of lcd.
* Add an example
* Support a function returning jquery element as the no-result handler
2018-01-12 16:05:11 +02:00
translatewiki.net 84e82520c8 Localisation updates from https://translatewiki.net. 2018-01-11 08:03:28 +01:00
Santhosh Thottingal d3ff6f09f2 Upgrade jquery in the example to 3.2.1 2018-01-10 15:58:50 +02:00
Santhosh Thottingal 37c9d66a2b Use .siblings to locate the suggestions, clear elements for efficiency (#285) 2018-01-10 09:13:56 +02:00