1
0
mirror of synced 2024-11-25 22:36:03 +03:00
Commit Graph

1363 Commits

Author SHA1 Message Date
David Foster
3ce3ad7fb0 Allow an empty string to be used as the placeholder title. 2014-04-01 14:22:41 -07:00
Lee Boynton
2d6b74c2ac Also check if search input should be focussed for multiselects 2014-03-31 21:01:06 +01:00
Kevin Brown
df7b7ba95c Merge pull request #2220 from bigmihail/master
Added translation for formatMatches
2014-03-30 11:03:15 -04:00
Mihail
b2c3dbc0ab Added translation for formatMatches
In accordance with changes in the file select2_locale_en.js.template
2014-03-30 13:30:45 +03:00
Kevin Brown
901a5994c3 Merge pull request #2215 from pineapple-thief/pineapple-thief
Update select2.js
2014-03-29 14:09:29 -04:00
Lee Boynton
ed0bae39c9 Check if search should be focused when the dropdown is activated 2014-03-28 14:56:45 +00:00
Lee Boynton
ad21d01693 Check if search input should be focussed when opening 2014-03-28 14:46:41 +00:00
pineapple-thief
70873abe9d Update select2.js
Fixes unpleasant glitch where initializing select2 on select where first input option tag has non-breakable space in innerText causes selected option to be displayed as "undefined" until user changes selection. (i.e. HTML was like <option value>&nbsp;</option>, that's what Rails 3 f.select helper generate by default).
2014-03-28 15:45:38 +11:00
Kevin Brown
cbd2a70dc3 Merge pull request #2203 from jesperronn/simplify-selectors
Reduced 10 level deep nesting of CSS rules. Instead, using the simpler d...
2014-03-23 17:14:35 -04:00
Jesper Rønn-Jensen
7390721038 Reduced 10 level deep nesting of CSS rules. Instead, using the simpler depth-0,-1,-2,etc for adding padding to the result when nested.
Greatly simplifies complexity of expressions and reduces (hopefully) rendering time.

From https://developers.google.com/speed/docs/best-practices/rendering#UseEfficientCSSSelectors
Descendant selectors are inefficient because, for each element that matches the key, the browser must also traverse up the DOM tree, evaluating every ancestor element until it finds a match or reaches the root element.
2014-03-23 21:50:35 +01:00
Kevin Brown
774a0d7765 modified version identifiers in descriptors for release 3.4.6 2014-03-22 22:30:17 -04:00
Kevin Brown
5b2516818c Fix sed issues in the release scripts
Passing in a blank string after `-i` will cause sed to fail, as it
tries to interpret it as a file (which does not exist) and bails
out.
2014-03-22 22:28:42 -04:00
Kevin Brown
2752563c80 Merge pull request #2096 from springboardretail/mobile-fixes
make selection on iOS more intuitive
2014-03-21 20:36:40 -04:00
Kevin Brown
63f342a12f Revert "Add hideSelectionFromResult function"
This reverts commit 84cf134a4e.

New problems found in:
https://github.com/ivaynberg/select2/issues/2196

Original issue:
https://github.com/ivaynberg/select2/issues/1538

Pull request:
https://github.com/ivaynberg/select2/pull/2032
2014-03-21 19:50:30 -04:00
Kevin Brown
d9f54a617c Merge pull request #2200 from diogotrentini/master
Fix bug related to dropdown position in Firefox and IE
2014-03-20 21:29:21 -04:00
Diogo Trentini
6c731f4181 Fix method to get space above the dropdown
It's better to get the scrollTop value from window rather than body
to update enoughRoomAbove variable. This method is supported by
the main browsers.
2014-03-20 21:45:41 -03:00
Igor Vaynberg
e51e7a64ba Merge pull request #2176 from mattslocum/master
Fix Focus war with modals
2014-03-18 16:34:56 -07:00
Adam Schepis
eb09dfcce0 make selection on iOS more intuitive
allow touchend to cause selection of touched item.
Detect touchmove events so that selection of touched item can be canceled
2014-03-13 22:24:19 -04:00
Matt Slocum
2342d91925 Fix Focus war with modals
Bootstrap modal (and maybe others) require focus to maintain in the modal (because that what a modal is). The dropdown is outside of the modal, so we need to stopPropagation on the event so the modal doesn't know.
2014-03-11 12:14:17 -06:00
Kevin Brown
2d906ee10f Merge pull request #2140 from ivaynberg/issue_1541
Add `shouldFocusInput` option [Fix #1541]
2014-03-07 10:14:32 -05:00
Kevin Brown
51e5d436ff Merge pull request #2160 from s7anley/bugfix/2073-select2-removing
Multiselect items are not removed when event is prevented
2014-03-07 10:12:01 -05:00
Coleman Watts
43e381ed37 Provide context for evaluated functions 2014-03-05 21:02:06 -05:00
Kevin Brown
e6fbfcd101 Merge pull request #2125 from colemanw/evaluateFix
Fix evaluation of formatLoadMore
2014-03-05 20:57:43 -05:00
Ján Koščo
f3c6d6d51f After prevented removing of item in multiselect, proper item is focused 2014-03-05 11:27:08 +01:00
Ján Koščo
86a9c79b04 Removed unnecessary animation during unseint multiselect by close button 2014-03-05 11:27:03 +01:00
Ján Koščo
2059b5d4d3 Unselected item is returned as options only if event isn't prevented 2014-03-05 11:26:50 +01:00
Daniel Norman
660643ae87 Fix a typo in the docs. 2014-02-28 11:21:53 +01:00
Kevin Brown
ec97c818c8 Merge pull request #2151 from dhardtke/csp_fixes
fix select2 csp errors / warnings
2014-02-27 14:18:00 -05:00
dhardtke
60359f9d43 fix select2 csp errors / warnings 2014-02-27 20:07:57 +01:00
Igor Vaynberg
c3592c3f87 Merge pull request #2147 from juanluisrp/patch-1
Unit of measure px is redundant
2014-02-26 08:21:57 -08:00
Igor Vaynberg
27acc27d37 Merge pull request #2148 from djarnis73/patch-1
Update select2.css to prevent float & width style to leak in
2014-02-26 08:21:24 -08:00
djarnis73
b7695ec6a9 Update select2.css 2014-02-26 13:01:10 +01:00
Juan Luis Rodríguez Ponce
b3ecfaabca Unit of measure px is redundant
Remove 'px' when property is set to 0.
2014-02-26 12:13:19 +01:00
Kevin Brown
c5e13d3aa8 Merge pull request #2146 from ebraminio/master
Update and improve Persian (fa) translations
2014-02-25 19:39:20 -05:00
Ebrahim Byagowi
60c9320e1d Update and improve Persian (fa) translations 2014-02-26 03:33:23 +03:30
Kevin Brown
d87e93dd45 Add shouldFocusInput option [Fix #1541]
This adds a `shouldFocusInput` option that determines whether or
not the focusser should be automatically focused.  By default, the
focusser will always be focused, unless `minimumResultsForSearch`
is less than zero.

`close` on single selects took an option `params` argument which
at one point was used to tell the focusser to not automatically
focus.  This was added at one point when tweaking the mask [1]
and later reverted to fix a bug that came as a result [2].  The
leftovers of this code has been removed in this commit.

[1]: e162a4802c
[2]: 9bc68f089e
2014-02-21 20:06:21 -05:00
Kevin Brown
b2b5ebd637 Merge pull request #2129 from campbell/master
Bugfix - only selected options that are not disabled should be used when initializing a dropdown
2014-02-21 10:27:01 -05:00
Pete Campbell
2a4e026b49 Bugfix - only selected options that are not disabled should be used when initializing the dropdown 2014-02-17 21:16:26 -05:00
Coleman Watts
9460b0c9b6 Fix evaluation of formatLoadMore 2014-02-14 17:14:12 -08:00
Kevin Brown
0636e42cbc Merge pull request #2098 from gdi2290/patch-1
update copyright year
2014-02-08 15:31:20 -05:00
Kevin Brown
97af0a39d9 Merge pull request #2106 from PeterMozesMerl/master
Update select2_locale_hu.js
2014-02-08 15:30:22 -05:00
PeterMozesMerl
b3d2d25ca2 Update select2_locale_hu.js
Language: "karakter". Grammar: missing comma.
2014-02-06 23:59:54 +01:00
PatrickJS
218021789f update copyright year 2014-02-03 23:44:44 -08:00
Kevin Brown
3c28c35503 Merge pull request #2095 from mkurz/readonly_chaining
Allow chaining for .select2('readonly', ...)
2014-02-03 15:46:53 -08:00
Kevin Brown
beabb63f03 Merge pull request #2092 from colemanw/strings
Accept strings as well as functions for localization
2014-02-03 15:41:32 -08:00
Matthias Kurz
bd3bd55719 Allow chaining for .select2('readonly', ...) 2014-02-03 16:07:23 +01:00
Coleman Watts
175c78441f Accept strings as well as functions for localization 2014-01-31 21:04:36 -08:00
Kevin Brown
596cf52d07 Merge pull request #2070 from jeanmonod/master
Allow to display item created by createSearchChoice at the end of the dropdown
2014-01-24 16:58:51 -08:00
Jeanmonod David
ed77cab7d5 Allow to display item created by createSearchChoice at the end of the list
ref #595
2014-01-24 18:54:56 +01:00
Kevin Brown
fb6e863839 Merge pull request #2065 from jdecuyper/hideSelectionFromResult-fix
Fix for hideSelectionFromResult
2014-01-21 10:05:44 -08:00