39 Commits

Author SHA1 Message Date
Abijeet
cfbfc5d2ff Remove unused variable and add uls prefix for CSS class 2023-01-16 15:04:12 +02:00
NikG
cd1452eb76 Enable up/down keys for navigating the ULS menu 2023-01-16 15:04:12 +02:00
Santhosh Thottingal
2ca3a1a36a For language links, use full space in <li> elements
If the link takes full space in <li>, the click or control click events
can originate from a wider space. Currently the <a> tags are surrounded
by padding of <li>.

See https://phabricator.wikimedia.org/T308688
2022-06-13 11:13:38 +05:30
Amir E. Aharoni
c16a7dbdab Change font-size from 1.2em to 1.143em
Also remove the unit from line-height.

Based on Volker's review of the previous change.
2022-01-26 15:17:01 +02:00
Amir E. Aharoni
f91700b77b Change font-size unit from px to em
The convention to avoid px in font-size and use em instead was
added to Wikimedia coding conventions was added in December 2020:
https://www.mediawiki.org/wiki/Manual:Coding_conventions/CSS#Don't_rely_on_px_unit_based_values

Now it's also enforced using stylelint.

This commit changes all CSS font-size values that were still in px
to em units.
2022-01-24 11:19:29 +02:00
Ed Sanders
d53beca719 Update linters
* Update eslint and stylelint config
* Fix Gruntfile.js to actually run stylelint
2019-11-13 04:14:16 +02:00
Volker E
c127858025 Don't cut-off language names vertically (#328)
Bug: [T210111](https://phabricator.wikimedia.org/T210111)
2018-11-22 10:22:17 +05:30
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
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
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
Santhosh Thottingal
2a77df6c41 Use eslint and stylelint, fix all errors (#282)
* Use eslint and stylelint, fix all errors

* Remove jshint, jsbeautify
* Use Object.keys directly since that is available in all major browsers
* Fixes for eslint, stylelint errors
* stylelint is not included in grunt test yet because jquery.uls.mobile.css
  has so many !important and need to figure out whether they are really needed
2018-01-04 15:58:35 +02:00
Volker E
18a2006708 Update .uls-lcd-region-title to conform to WCAG level AA
Updating `.uls-lcd-region-title` to be on the safe side with color contrast, 
conforming to WCAG level AA no matter what `background-color` grey or `font-size`.
2017-10-09 19:45:07 -07:00
Santhosh Thottingal
34df56f650 Merge pull request #272 from wikimedia/fix-no-search-results
Improve how "no search results" is handled
2017-09-11 11:32:46 +05:30
Volker E
70eba564d8 Improve color values and CSS 2017-09-07 19:04:08 -07:00
Niklas Laxström
ca550e22cd Improve how "no search results" is handled
* Drop the ugly height: 100% hack and do it properly and remove TODO
* after( $suggestions.show() ) seems to not work as expected in recent
  jQuery versions. Changed it to manipulate the presence of 'hide'
  class properly.
* Consistency fix in a comment
* Fixed a bug where creating multiple ULS instances would break the
  "no search results" functionality. This is because we were appending
  a jQuery element wrapped in a $(). This is obviously a no-op and a
  regression when the template actually was a string and not jQuery.
  Fixed by using clone() on it.

https://phabricator.wikimedia.org/T175233
2017-09-07 11:22:26 +02:00
Niklas Laxström
8a8f502de7 Style changes to lcd
This change is larger than it should because I came across lots of
unused CSS which I removed or simplified.

https://phabricator.wikimedia.org/T138235
2016-08-17 16:29:08 +02:00
Santhosh Thottingal
ae9dda23b7 Merge branch 'nikerabbit-badges' 2016-06-09 15:08:28 +05:30
Niklas Laxström
25775dd147 Adjust styles and code to support custom list bullets
Tweak specificty of the rule that hides bullets so that it is easy
to override.

Move dir and lang attributes from <li> to <a> so that the bullets
appear on the correct side for reverse directionality scripts.

Change-Id: Ic0d0c5220b0b374c2a3a19023c40d81f3e20007c
2016-06-09 15:08:15 +05:30
Niklas Laxström
fb12b5e25d Avoid scrollbars in RTL 2016-06-02 10:55:51 +03:00
Niklas Laxström
2a538b78e1 Remove compact mode
Make the regular mode look like compact mode
2016-04-21 15:27:49 +05:30
Santhosh Thottingal
49497d7078 Avoid overriding grid css for language list
Change-Id: I7606c5af716f2094bc1766a95123a68413634c91
2013-11-05 19:49:38 +05:30
Pau Giner
ddcf725ca6 Adjusted language list height
The language list height has been reduced in order to
avoid overflow on small screens.
2013-05-30 16:19:00 +02:00
Niklas Laxström
5d6c83d945 Add spaces 2013-03-15 10:21:59 +00:00
Pau Giner
36a699f89f Border radius removed from the search info
Since the search information shown when no elements are found is no longer
the element at the bottom, there is no need for rounded bottom corners that match the ULs panel.
2013-02-06 11:04:38 +01:00
Amir E. Aharoni
e78a2507d7 Whitespace 2012-12-30 20:34:32 +02:00
pginer
245ced8c7c Adjusting CSS precedence of rules
Some selectors have been adjusted to be made more specifics
when the modified Grid rules took unintended preference due to last modifications.
2012-11-26 13:58:15 +01:00
pginer
2ac75f61c5 Cursor adjustment for regions in the 'no found' view
Sets the cursor type to pointer so that the regions at the bottom
of the 'no found' view act as links (hand cursor is ahown on hover).
2012-11-20 10:03:03 +01:00
pginer
27039e1141 Fixes CSSLint issues for jquery.uls.css
CSS adjustments and JS modifications (adding classes to HTML elemnts)
to solve issues reported by CSS Lint when validating jquery.uls.css
2012-11-19 17:26:34 +01:00
pginer
6fa03963f1 Fixes CSSLint issues for jquery.uls.lcd.css
CSS adjustments and JS modifications (adding classes to HTML elements)
to solve issues reported by CSS Lint when validating jquery.uls.lcd.css

Change-Id: Ic604984b1a677f0e18796d6ce131736d6b9d6c3a
2012-11-19 20:13:12 +05:30
pginer
89a502fdb5 Emphasize search bar and better connection to the list
The style for the search zone has been modified to emphasize it,
 and margins for the language list have been modified to avoid blank separation between search bar and the list.
2012-10-17 13:29:54 +02:00
Amir E. Aharoni
9d38d9bd64 Fix a few trivial CSS lint issues 2012-10-08 08:35:14 +02:00
Amir E. Aharoni
972247b895 Remove unecessary whitespace 2012-10-07 17:17:36 +02:00
amire80
f9e3e148e3 Add basic support for dir and lang attributes for autonyms
Added a util function for getting the language's direction.

Added lang and dir attributes for every language item in the list.
2012-09-24 16:34:06 -07:00
Santhosh Thottingal
f837ed904a Fix Bug 39922 - The "No results found" view lacks suggested languages
noresultsview is part of uls.lcd now, moved the html template too.

Change-Id: I9aee0ab1b62e61c3ec0e2c89f7d07b7a4432ef33
2012-09-03 19:31:41 +05:30
pginer
bc98b8ff1d CSS adjustments on color and sizes
Small adjustments on color to make it compliant with the Agora palette,
cross-browser gradient code added according to CSS WMF guidelines, and
adjustment of element sizes.

And whitespace and new line cleanups

Change-Id: I08890009eff9ed5edec77855467529eb07eaeb57
2012-08-17 17:23:39 +05:30
Siebrand Mazeland
e0bf84cb15 Fix some issues pointed out by IDE.
* Update .gitignore to ignore .idea.
* Removed unused local variables.
* use local context and Message class instead of deprecated wfMsg* methods.
* Remove redundant px in CSS where possible.
* Combine CSS statements where possible.
* Replace b by strong.

Change-Id: I9d5ed7b7ce585a1c101044254bcbdfc33d42afc1
2012-08-15 17:32:49 +02:00
pginer
87897014fc CSS fixes for colors and size consistency
Small CSS adjustments to:
* Reduce ULS vertical size to adapt to the 8-row layout.
* Use more contrast in colors to better comply with WCAG.
* Add overflow properties to regions in map to avoidlong texts to overlap.

Change-Id: I0498f68e32b978f2e1d8c2d4c5e788c71483590d
2012-08-15 14:24:53 +02:00
Santhosh Thottingal
063805538b Implement visual language grouping in ULS
Added a utility callback function to sort languages by autonym.
Added CSS fix for group separatos.

Change-Id: I73c7c6518a85e4ea7999be3ef92a121e877610e8
2012-08-07 13:42:20 +05:30
Santhosh Thottingal
0a681a85fe Rearranging Files
* Seperating standalone jQuery ULS plugin and extension related code
* lib/jquery.uls can be submodule, but not now.

Change-Id: I7d9cb47daa88dd1a27ceda602a08cab0073caf33
2012-08-03 12:24:04 +05:30