26 |
--------------------------------------------------------------------------------
/bootstrap-show-password.jquery.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "bootstrap-show-password",
3 | "version": "1.3.0",
4 | "title": "Bootstrap Show Password",
5 | "description": "Show/hide password plugin for twitter bootstrap.",
6 | "author": {
7 | "name": "zhixin wen",
8 | "email": "wenzhixin2010@gmail.com",
9 | "url": "http://wenzhixin.net.cn/"
10 | },
11 | "licenses": [
12 | {
13 | "type": "MIT License",
14 | "url": "http://opensource.org/licenses/MIT"
15 | }
16 | ],
17 | "dependencies": {
18 | "jquery": ">=1.7"
19 | },
20 | "keywords": ["bootstrap.password", "show.password", "hide.password"],
21 | "homepage": "https://github.com/wenzhixin/bootstrap-show-password",
22 | "demo": "http://wenzhixin.net.cn/p/bootstrap-show-password/",
23 | "bugs": {
24 | "url": "https://github.com/wenzhixin/bootstrap-show-password/issues"
25 | },
26 | "docs": "https://github.com/wenzhixin/bootstrap-show-password#usage",
27 | "download": "https://github.com/wenzhixin/bootstrap-show-password/archive/master.zip"
28 | }
29 |
--------------------------------------------------------------------------------
/docs/_i18n/en.yml:
--------------------------------------------------------------------------------
1 | pages:
2 | home:
3 | title: "Bootstrap Show Password"
4 | lead: "Bootstrap Show Password is a show/hide password plugin."
5 | sub_title: "Designed for twitter bootstrap"
6 | sub_lead: "Bootstrap Show Password has been designed to reduce development time and to require no specific knowledge from developers. It is both featherweight and feature-rich."
7 | download: "Download"
8 | current_version: "Current version:"
9 | getting_started:
10 | title: "Getting started"
11 | lead: "An overview of Bootstrap Show Password, how to download and use, basic templates, and more."
12 | examples:
13 | title: "Examples"
14 | lead: "The examples of Bootstrap Show Password."
15 | documentation:
16 | title: "Documentation"
17 | lead: "The documentation contains Constructor, Events, Methods."
18 | donate:
19 | title: "Donate"
20 | lead: "If you like Bootstrap Show Password, if your project uses Bootstrap Show Password, if you want Bootstrap Show Password do better..."
21 | common:
22 | social_tip: "If you like Bootstrap Show Password: "
23 | help: "Questions/Helps: "
24 |
--------------------------------------------------------------------------------
/docs/_i18n/en/getting-started/usage.md:
--------------------------------------------------------------------------------
1 | # Usage []({{ site.repo }}/blob/develop/docs/_i18n/{{ site.lang }}/getting-started/usage.md)
2 |
3 | ---
4 |
5 | Include jQuery library, bootstrap library (if your project doesn't use it already) and `bootstrap-show-password.js` in the head tag or at the very bottom of your document, just before the closing body tag (usually recommended for better performance).
6 |
7 | ```html
8 |
9 |
10 |
11 | ```
12 |
13 | ---
14 |
15 | The plugin acts on `` elements (typically password fields).
16 |
17 | ## Via data attributes
18 |
19 | Activate Bootstrap Show Password without writing JavaScript. Set `data-toggle="password"` on a normal input.
20 |
21 | ```html
22 |
23 | ```
24 | ## Via JavaScript
25 |
26 | Call a Bootstrap Show Password with id select with JavaScript.
27 |
28 | ```html
29 |
30 | ```
31 |
32 | ```js
33 | $('#password').password()
34 | ```
35 |
--------------------------------------------------------------------------------
/LICENSE:
--------------------------------------------------------------------------------
1 | The MIT License (MIT)
2 |
3 | Copyright (c) 20010-2019 文翼
4 |
5 | Permission is hereby granted, free of charge, to any person obtaining a copy
6 | of this software and associated documentation files (the "Software"), to deal
7 | in the Software without restriction, including without limitation the rights
8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9 | copies of the Software, and to permit persons to whom the Software is
10 | furnished to do so, subject to the following conditions:
11 |
12 | The above copyright notice and this permission notice shall be included in all
13 | copies or substantial portions of the Software.
14 |
15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21 | SOFTWARE.
22 |
--------------------------------------------------------------------------------
/docs/donate.md:
--------------------------------------------------------------------------------
1 | ---
2 | layout: default
3 | title: pages.donate.title
4 | slug: donate
5 | lead: pages.donate.lead
6 | ---
7 |
8 | {% tf donate.md %}
9 |
10 |
41 |
--------------------------------------------------------------------------------
/docs/_i18n/sp.yml:
--------------------------------------------------------------------------------
1 | pages:
2 | home:
3 | title: "Bootstrap Show Password"
4 | lead: "Bootstrap Show Password es un módulo para mostrar/ocultar contraseñas."
5 | sub_title: "Diseñada para ser usada con el proyecto Bootstrap de Twitter"
6 | sub_lead: "Bootstrap Mostrar contraseña ha sido diseñado para reducir el tiempo de desarrollo y no requiere de conocimientos específicos de parte de sus desarrolladores. Es liviano y rico en funciones."
7 | download: "Descargar"
8 | current_version: "Versión actual:"
9 | getting_started:
10 | title: "Empezando"
11 | lead: "Una descripción general de Bootstrap Show Password, cómo descargar y usarlo, plantillas básicas y más."
12 | examples:
13 | title: "Ejemplos"
14 | lead: "Los ejemplos de Bootstrap Show Password."
15 | documentation:
16 | title: "Documentación"
17 | lead: "La documentación contiene el Constructor, Eventos, Métodos."
18 | donate:
19 | title: "Donar"
20 | lead: "Si le gusta Bootstrap Show Password, si su proyecto usa Bootstrap Show Password, si desea que Bootstrap Show Password mejore..."
21 | common:
22 | social_tip: "Si le gusta Bootstrap Show Password: "
23 | help: "Preguntas/Ayudas: "
24 |
--------------------------------------------------------------------------------
/docs/assets/js/common.js:
--------------------------------------------------------------------------------
1 | $(function () {
2 | $('h1').find('a')
3 | .attr('target', '_blank')
4 | .addClass('edit-page-link')
5 | .text('Edit on GitHub')
6 |
7 | // languages
8 | var currentLanguage = 'en'
9 | var baseDir = '../'
10 | var pathDir = location.href.replace(/\/$/, '').split('/').pop()
11 | $('[data-language]').each(function (i) {
12 | var $this = $(this),
13 | language = $this.data('language')
14 |
15 | // default
16 | if (i === 0) {
17 | $this.addClass('active')
18 | }
19 | if (location.href.indexOf('/' + language + '/') !== -1) {
20 | $this.addClass('active').siblings().removeClass('active')
21 | $('.language').text($(this).text())
22 | currentLanguage = language
23 | }
24 | })
25 | if (currentLanguage !== 'en') {
26 | baseDir = '../../'
27 | }
28 | $('[data-language]').each(function (i) {
29 | var language = $(this).data('language')
30 | $(this).find('a').attr('href', baseDir +
31 | (language === 'en' ? '' : language + '/') + pathDir)
32 | })
33 |
34 | $('.start-table').next().bootstrapTable({
35 | search: true,
36 | showToggle: true,
37 | showColumns: true,
38 | mobileResponsive: true
39 | })
40 | })
41 |
--------------------------------------------------------------------------------
/docs/_includes/footer.html:
--------------------------------------------------------------------------------
1 |
3 | {% if page.layout != "examples" %}
4 | {% tf footer.html %}
5 | {% endif %}
6 |
7 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
--------------------------------------------------------------------------------
/docs/_i18n/en/getting-started/download.md:
--------------------------------------------------------------------------------
1 | # Download []({{ site.repo }}/blob/develop/docs/_i18n/{{ site.lang }}/getting-started/download.md)
2 |
3 | ---
4 |
5 |
6 | Bootstrap Show Password (currently v{{ site.current_version }}) has a few easy ways to quickly get started, each one appealing to a different skill level and use case. Read through to see what suits your particular needs.
7 |
8 |
9 | ## Source code
10 |
11 | Source JavaScript, along with our docs.
12 |
13 | Download source
14 |
15 | ## Clone or fork via GitHub
16 |
17 | Via GitHub
18 |
19 | ## CDN
20 |
21 | The folks over at [UNPKG](https://unpkg.com/) graciously provide CDN support for CSS and JavaScript of Bootstrap Show Password. Just use these CDN links.
22 |
23 | ```html
24 |
25 |
26 | ```
27 |
28 | ## NPM
29 |
30 | Install and manage Bootstrap Show Password's CSS, JavaScript using [NPM](http://npmjs.com).
31 |
32 | ```bash
33 | $ npm install bootstrap-show-password
34 | ```
35 |
--------------------------------------------------------------------------------
/CHANGELOG.md:
--------------------------------------------------------------------------------
1 | ## CHANGELOG
2 |
3 | ### 1.3.0
4 |
5 | - **New:** Supported bootstrap v5.
6 | - **New:** Supported all attributes without `data-*`.
7 | - **Update:** Fix bootstrap v3 old version is `undefined` bug.
8 |
9 | ### 1.2.1
10 |
11 | - **New:** Added font-awesome svg support.
12 | - **New:** Added `size` option of the input group.
13 |
14 | ### 1.2.0
15 |
16 | - **New:** Rewrote the src to ES6.
17 | - **New:** Supported bootstrap v4.
18 | - **New:** Use Font Awesome v5 as default.
19 | - **New:** Supported `maxlength` attribute.
20 | - **New:** Supported `disabled` attribute.
21 | - **New:** Updated the docs and added examples.
22 |
23 | ### 1.1.2
24 |
25 | * Add support for google material design icons, by using the data-eye-class-position-inside property.
26 |
27 | ### 1.1.1
28 |
29 | * Add `focus` method.
30 |
31 | ### 1.1.0
32 |
33 | * Add support for google material design icons, by usgin the ```data-eye-class-position-inside``` property.
34 |
35 | ### 1.0.3
36 |
37 | * Add `eyeClass`, `eyeOpenClass`, `eyeCloseClass` to use custom font (for example Font Awesome) instead of Bootstrap's default Glyphicon.
38 |
39 | ### 1.0.2
40 |
41 | * Add `val` option.
42 |
43 | ### 1.0.1
44 |
45 | * Via data attribute support.
46 | * Rename file name to bootstrap-show-password.js
47 | * Add bootstrap-show-password.min.js
48 |
49 | ### 1.0.0
50 |
51 | * Initial release
52 |
--------------------------------------------------------------------------------
/docs/home.md:
--------------------------------------------------------------------------------
1 | ---
2 | layout: home
3 | title: pages.home.title
4 | ---
5 |
6 |
7 |
';
111 | }
112 | this.$menu.find('ul').append(this.$list);
113 |
114 | var backElem = '' + this.options.toTopText + '';
116 | this.$menu.append(backElem);
117 |
118 | $(this.options.container).append(this.$menu);
119 | },
120 |
121 | initAffix: function() {
122 | $('body').scrollspy({target: '.bs-sidebar'});
123 |
124 | if (typeof this.options.top === 'undefined') {
125 | this.options.top = this.options.container;
126 | }
127 | if (typeof this.options.top === 'string' && $(this.options.top).length) {
128 | this.options.top = $(this.options.top).offset().top;
129 | }
130 | if (typeof this.options.bottom === 'string' && $(this.options.bottom).length) {
131 | this.options.bottom = $(this.options.bottom).outerHeight(true);
132 | }
133 | this.$menu.affix({
134 | offset: {
135 | top: this.options.top || 0,
136 | bottom: this.options.bottom || 0
137 | }
138 | });
139 | }
140 | };
141 |
142 | $.fn.sideNav = function() {
143 | var option = arguments[0],
144 | args = arguments,
145 | value;
146 |
147 | this.each(function() {
148 | var $this = $(this), data = $this.data('sideNav'),
149 | options = $.extend({}, $.fn.sideNav.defaults, $this.data(), option);
150 |
151 | if (!data) {
152 | data = new SideNav($this);
153 | data.init(options, true);
154 | $this.data('sideNav', data);
155 | } else {
156 | data.init(options);
157 | }
158 | });
159 |
160 | return value ? value : this;
161 | };
162 |
163 | $.fn.sideNav.defaults = {
164 | container: 'body',
165 | hs: ['h2', 'h3', 'h4'],
166 | smartId: false,
167 | top: undefined,
168 | bottom: undefined,
169 | toTopHref: '#top',
170 | toTopText: 'Back to top'
171 | };
172 |
173 | $(function () {
174 | $('[data-toggle="sidenav"]').sideNav();
175 | });
176 | })(jQuery);
177 |
--------------------------------------------------------------------------------
/dist/bootstrap-show-password.esm.min.js:
--------------------------------------------------------------------------------
1 | /**
2 | * bootstrap-show-password - Show/hide password plugin for twitter bootstrap.
3 | *
4 | * @version v1.3.0
5 | * @homepage https://github.com/wenzhixin/bootstrap-show-password
6 | * @author zhixin wen
7 | * @license MIT
8 | */
9 |
10 | import"core-js/modules/es.array.concat.js";import"core-js/modules/es.array.find.js";import"core-js/modules/es.array.includes.js";import"core-js/modules/es.array.index-of.js";import"core-js/modules/es.array.join.js";import"core-js/modules/es.function.name.js";import"core-js/modules/es.object.to-string.js";import"core-js/modules/es.parse-int.js";import"core-js/modules/es.regexp.exec.js";import"core-js/modules/es.string.replace.js";function e(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var s=n.call(e,t||"default");if("object"!=typeof s)return s;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:String(t)}function t(e){return t="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},t(e)}function n(t,n){for(var s=0;se.length)&&(t=e.length);for(var n=0,s=new Array(t);n=e.length?{done:!0}:{done:!1,value:e[o++]}},e:function(e){throw e},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var r,a=!0,l=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return a=e.done,e},e:function(e){l=!0,r=e},f:function(){try{a||null==n.return||n.return()}finally{if(l)throw r}}}}var i=5;try{var r=$.fn.dropdown.Constructor.VERSION;void 0!==r&&(i=parseInt(r,10))}catch(e){}try{var a=bootstrap.Tooltip.VERSION;void 0!==a&&(i=parseInt(a,10))}catch(e){}var l={html:{inputGroups:{3:['',""],4:['"],5:['"]}[i]}},c=function(e){var t=arguments,n=!0,s=1;return e=e.replace(/%s/g,(function(){var e=t[s++];return void 0===e?(n=!1,""):e})),n?e:""},p=function(){function e(t,n){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.options=n,this.$element=$(t),this.isShown=!1,this.init()}var t,s,i;return t=e,(s=[{key:"init",value:function(){var e,t;"before"===this.options.placement?(e="insertBefore",t="input-group-prepend"):(this.options.placement="after",e="insertAfter",t="input-group-append"),this.$element.wrap('')),this.$text=$('')[e](this.$element).css("display",this.$element.css("display")).val(this.$element.val()).hide();var n,s=o(this.$element[0].attributes);try{for(s.s();!(n=s.n()).done;){var i=n.value;i.specified&&!["id","type"].includes(i.name)&&0!==i.name.indexOf("data-")&&this.$text.attr(i.name,i.value)}}catch(e){s.e(e)}finally{s.f()}this.$icon=$(["".concat(c(l.html.inputGroups[0],t,this.options.message),'\n \n ').concat(this.options.eyeClassPositionInside?this.options.eyeOpenClass:"","\n "),l.html.inputGroups[1]].join(""))[e](this.$text).css("cursor","pointer"),this.$text.off("keyup").on("keyup",$.proxy((function(){this.isShown&&this.$element.val(this.$text.val()).trigger("change")}),this)),this.$icon.off("click").on("click",$.proxy((function(){this.$text.val(this.$element.val()).trigger("change"),this.toggle()}),this))}},{key:"toggle",value:function(e){this[this.isShown?"hide":"show"](e)}},{key:"show",value:function(e){var t=$.Event("show.bs.password",{relatedTarget:e});this.$element.trigger(t),this.isShown=!0,this.$element.hide(),this.$text.show(),this.options.eyeClassPositionInside?this.$icon.find("i,svg").removeClass("icon-eye-open").addClass("icon-eye-close").html(this.options.eyeCloseClass):this.$icon.find("i,svg").removeClass("icon-eye-open ".concat(this.options.eyeOpenClass)).addClass("icon-eye-close ".concat(this.options.eyeCloseClass)),this.$text[this.options.placement](this.$element)}},{key:"hide",value:function(e){var t=$.Event("hide.bs.password",{relatedTarget:e});this.$element.trigger(t),this.isShown=!1,this.$element.show(),this.$text.hide(),this.options.eyeClassPositionInside?this.$icon.find("i,svg").removeClass("icon-eye-close").addClass("icon-eye-open").html(this.options.eyeOpenClass):this.$icon.find("i,svg").removeClass("icon-eye-close ".concat(this.options.eyeCloseClass)).addClass("icon-eye-open ".concat(this.options.eyeOpenClass)),this.$element[this.options.placement](this.$text)}},{key:"val",value:function(e){if(void 0===e)return this.$element.val();this.$element.val(e).trigger("change"),this.$text.val(e)}},{key:"focus",value:function(){this.$element.focus()}}])&&n(t.prototype,s),i&&n(t,i),Object.defineProperty(t,"prototype",{writable:!1}),e}();p.DEFAULTS={placement:"after",message:"Click here to show/hide password",size:void 0,eyeClass:"fa",eyeOpenClass:"fa-eye",eyeCloseClass:"fa-eye-slash",eyeClassPositionInside:!1};var u=$.fn.password;$.fn.password=function(){var e,n=arguments[0],s=arguments,o=["show","hide","toggle","val","focus"];return this.each((function(){var i=$(this),r=i.data("bs.password"),a=$.extend({},p.DEFAULTS,i.data(),"object"===t(n)&&n);if("string"==typeof n){if($.inArray(n,o)<0)throw new Error("Unknown method: ".concat(n));e=r[n](s[1])}else r?r.init(a):(r=new p(i,a),i.data("bs.password",r))})),e||this},$.fn.password.Constructor=p,$.fn.password.noConflict=function(){return $.fn.password=u,this},$((function(){$('[data-toggle="password"]').password()}));
11 |
--------------------------------------------------------------------------------
/docs/assets/js/template.js:
--------------------------------------------------------------------------------
1 | $(function () {
2 | var url = location.search.replace(/\?v=\d+&/, '').replace(/\?v=VERSION&/, '')
3 | $.ajax({
4 | type: 'GET',
5 | url: url + '?v=VERSION', // todo: add version to solve cache problem
6 | dataType: 'html',
7 | global: false,
8 | cache: true, // (warning: setting it to false will cause a timestamp and will call the request twice)
9 | success: function (data) {
10 | $('#example').html(data)
11 | $('#source').text(_beautifySource(data))
12 | window.hljs.highlightAll()
13 | }
14 | })
15 |
16 | if (/js\.html$/.test(url)) {
17 | $('[data-nav="javascript"]').addClass('active')
18 | } else {
19 | $('[data-nav="attributes"]').addClass('active')
20 | }
21 | $('[data-nav]').click(function () {
22 | if ($(this).hasClass('active')) {
23 | return false
24 | }
25 | if (/js\.html$/.test(location.href)) {
26 | location.href = location.href.replace(/\.js\.html$/, '.html')
27 | } else {
28 | location.href = location.href.replace(/\.html$/, '.js.html')
29 | }
30 | })
31 |
32 | $('.nav-tabs').toggle(['events.html', 'methods.html'].indexOf(url) === -1)
33 | })
34 |
35 | window._config = {
36 | isDebug: location.hash.slice(1) === 'is-debug' ||
37 | ['localhost'].indexOf(location.hostname) > -1,
38 | cdnUrl: 'https://unpkg.com/bootstrap-show-password@1.3.0/dist/',
39 | localUrl: 'http://localhost:8080/github/bootstrap-show-password/src/'
40 | }
41 |
42 | function _getLink(file) {
43 | var url = file
44 | if (!/^http/.test(file)) {
45 | url = window._config.cdnUrl + file
46 |
47 | if (window._config.isDebug) {
48 | url = window._config.localUrl + file.replace(/\.min/, '') + '?t=' + (+new Date())
49 | }
50 | }
51 | return ''
52 | }
53 |
54 | function _getScript(file, isScriptTag) {
55 | var url = file
56 | if (!/^http/.test(file)) {
57 | url = window._config.cdnUrl + file
58 |
59 | if (window._config.isDebug) {
60 | url = window._config.localUrl + file.replace(/\.min/, '') + '?t=' + (+new Date())
61 | }
62 | }
63 | if (isScriptTag) {
64 | return ''
65 | }
66 | return url
67 | }
68 |
69 | function _link(file) {
70 | $('head').append(_getLink(file))
71 | }
72 |
73 | function _script(file, callback) {
74 | var head = document.getElementsByTagName('head')[0]
75 | var script = document.createElement('script')
76 |
77 | script.src = _getScript(file)
78 |
79 | var done = false
80 | // Attach handlers for all browsers
81 | script.onload = script.onreadystatechange = function() {
82 | if (!done && (!this.readyState ||
83 | this.readyState === 'loaded' || this.readyState === 'complete')) {
84 | done = true
85 | if (callback)
86 | callback()
87 |
88 | // Handle memory leak in IE
89 | script.onload = script.onreadystatechange = null
90 | }
91 | }
92 |
93 | head.appendChild(script)
94 | }
95 |
96 | function _scripts(scripts, callback) {
97 | var eachSeries = function (arr, iterator, callback_) {
98 | var callback = callback_ || function () {}
99 | if (!arr.length) {
100 | return callback()
101 | }
102 | var completed = 0
103 | var iterate = function () {
104 | iterator(arr[completed], function (err) {
105 | if (err) {
106 | callback(err)
107 | callback = function () {}
108 | } else {
109 | completed += 1
110 | if (completed >= arr.length) {
111 | callback(null)
112 | } else {
113 | iterate()
114 | }
115 | }
116 | })
117 | }
118 | iterate()
119 | }
120 |
121 | eachSeries(scripts, _script, function () {
122 | callback()
123 | })
124 | }
125 |
126 | function _beautifySource(data) {
127 | var lines = data.split('\n')
128 | var scriptStart = lines.indexOf('', scriptStart)
130 | var strings = lines.slice(scriptStart + 1, scriptEnd)
131 | strings = $.map(strings, function (s) {
132 | return $.trim(s)
133 | })
134 | /* eslint-disable no-control-regex */
135 | var obj = eval('(' + strings.join('').replace(/[^\u0000-\u007E]/g, '')
136 | .replace(/^init\((.*)\)$/, '$1') + ')')
137 |
138 | var theme = location.pathname.replace('/examples/template', '')
139 | .replace('-', '').replace('.html', '')
140 | var result = []
141 |
142 | if (theme === 'v3') {
143 | result.push(
144 | ''
145 | )
146 | } else if (theme === 'svg') {
147 | result.push(
148 | ''
149 | )
150 | } else {
151 | result.push(
152 | '',
153 | ''
154 | )
155 | }
156 | result = result.concat($.map(obj.links, _getLink))
157 | result.push('')
158 |
159 | result.push('')
160 | if (theme === 'v3') {
161 | result.push(
162 | ''
163 | )
164 | } else if (theme === 'svg') {
165 | result.push(
166 | '',
167 | ''
168 | )
169 | } else {
170 | result.push(
171 | ''
172 | )
173 | }
174 | result = result.concat($.map(obj.scripts, function (script) {
175 | return _getScript(script, true)
176 | }))
177 | lines = result.concat(lines.slice(scriptEnd + 1))
178 |
179 | var mountedStart = lines.indexOf(' function mounted() {')
180 | var mountedEnd = lines.indexOf(' }', mountedStart)
181 | lines[mountedStart] = ' $(function() {'
182 | lines[mountedEnd] = ' })'
183 |
184 | return lines.join('\n')
185 | }
186 |
187 | window.init = function (options_) {
188 | var options = $.extend({
189 | title: '',
190 | desc: '',
191 | links: [],
192 | scripts: [],
193 | bootstrapVersion: 3,
194 | callback: function () {
195 | if (typeof window.mounted === 'function') {
196 | window.mounted()
197 | }
198 | }
199 | }, options_)
200 |
201 | $('#header h1 span').html(options.title)
202 | $('#header div').html(options.desc)
203 | $.each(options.links, function (i, file) {
204 | _link(file)
205 | })
206 | _scripts(options.scripts, options.callback)
207 | }
208 |
--------------------------------------------------------------------------------
/dist/bootstrap-show-password.min.js:
--------------------------------------------------------------------------------
1 | /**
2 | * bootstrap-show-password - Show/hide password plugin for twitter bootstrap.
3 | *
4 | * @version v1.3.0
5 | * @homepage https://github.com/wenzhixin/bootstrap-show-password
6 | * @author zhixin wen
7 | * @license MIT
8 | */
9 |
10 | !function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(require("core-js/modules/es.array.concat.js"),require("core-js/modules/es.array.find.js"),require("core-js/modules/es.array.includes.js"),require("core-js/modules/es.array.index-of.js"),require("core-js/modules/es.array.join.js"),require("core-js/modules/es.function.name.js"),require("core-js/modules/es.object.to-string.js"),require("core-js/modules/es.parse-int.js"),require("core-js/modules/es.regexp.exec.js"),require("core-js/modules/es.string.replace.js"),require("jquery")):"function"==typeof define&&define.amd?define(["core-js/modules/es.array.concat.js","core-js/modules/es.array.find.js","core-js/modules/es.array.includes.js","core-js/modules/es.array.index-of.js","core-js/modules/es.array.join.js","core-js/modules/es.function.name.js","core-js/modules/es.object.to-string.js","core-js/modules/es.parse-int.js","core-js/modules/es.regexp.exec.js","core-js/modules/es.string.replace.js","jquery"],t):t(null,null,null,null,null,null,null,null,null,null,(e="undefined"!=typeof globalThis?globalThis:e||self).jQuery)}(this,(function(e,t,s,n,o,i,r,a,l,c,u){"use strict";function p(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var s=e[Symbol.toPrimitive];if(void 0!==s){var n=s.call(e,t||"default");if("object"!=typeof n)return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:String(t)}function d(e){return d="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},d(e)}function f(e,t){for(var s=0;se.length)&&(t=e.length);for(var s=0,n=new Array(t);s=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var i,r=!0,a=!1;return{s:function(){s=s.call(e)},n:function(){var e=s.next();return r=e.done,e},e:function(e){a=!0,i=e},f:function(){try{r||null==s.return||s.return()}finally{if(a)throw i}}}}var m=5;try{var v=u.fn.dropdown.Constructor.VERSION;void 0!==v&&(m=parseInt(v,10))}catch(e){}try{var g=bootstrap.Tooltip.VERSION;void 0!==g&&(m=parseInt(g,10))}catch(e){}var j={html:{inputGroups:{3:['',""],4:['"],5:['"]}[m]}},b=function(e){var t=arguments,s=!0,n=1;return e=e.replace(/%s/g,(function(){var e=t[n++];return void 0===e?(s=!1,""):e})),s?e:""},w=function(){function e(t,s){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.options=s,this.$element=u(t),this.isShown=!1,this.init()}var t,s,n;return t=e,(s=[{key:"init",value:function(){var e,t;"before"===this.options.placement?(e="insertBefore",t="input-group-prepend"):(this.options.placement="after",e="insertAfter",t="input-group-append"),this.$element.wrap('')),this.$text=u('')[e](this.$element).css("display",this.$element.css("display")).val(this.$element.val()).hide();var s,n=y(this.$element[0].attributes);try{for(n.s();!(s=n.n()).done;){var o=s.value;o.specified&&!["id","type"].includes(o.name)&&0!==o.name.indexOf("data-")&&this.$text.attr(o.name,o.value)}}catch(e){n.e(e)}finally{n.f()}this.$icon=u(["".concat(b(j.html.inputGroups[0],t,this.options.message),'\n \n ').concat(this.options.eyeClassPositionInside?this.options.eyeOpenClass:"","\n "),j.html.inputGroups[1]].join(""))[e](this.$text).css("cursor","pointer"),this.$text.off("keyup").on("keyup",u.proxy((function(){this.isShown&&this.$element.val(this.$text.val()).trigger("change")}),this)),this.$icon.off("click").on("click",u.proxy((function(){this.$text.val(this.$element.val()).trigger("change"),this.toggle()}),this))}},{key:"toggle",value:function(e){this[this.isShown?"hide":"show"](e)}},{key:"show",value:function(e){var t=u.Event("show.bs.password",{relatedTarget:e});this.$element.trigger(t),this.isShown=!0,this.$element.hide(),this.$text.show(),this.options.eyeClassPositionInside?this.$icon.find("i,svg").removeClass("icon-eye-open").addClass("icon-eye-close").html(this.options.eyeCloseClass):this.$icon.find("i,svg").removeClass("icon-eye-open ".concat(this.options.eyeOpenClass)).addClass("icon-eye-close ".concat(this.options.eyeCloseClass)),this.$text[this.options.placement](this.$element)}},{key:"hide",value:function(e){var t=u.Event("hide.bs.password",{relatedTarget:e});this.$element.trigger(t),this.isShown=!1,this.$element.show(),this.$text.hide(),this.options.eyeClassPositionInside?this.$icon.find("i,svg").removeClass("icon-eye-close").addClass("icon-eye-open").html(this.options.eyeOpenClass):this.$icon.find("i,svg").removeClass("icon-eye-close ".concat(this.options.eyeCloseClass)).addClass("icon-eye-open ".concat(this.options.eyeOpenClass)),this.$element[this.options.placement](this.$text)}},{key:"val",value:function(e){if(void 0===e)return this.$element.val();this.$element.val(e).trigger("change"),this.$text.val(e)}},{key:"focus",value:function(){this.$element.focus()}}])&&f(t.prototype,s),n&&f(t,n),Object.defineProperty(t,"prototype",{writable:!1}),e}();w.DEFAULTS={placement:"after",message:"Click here to show/hide password",size:void 0,eyeClass:"fa",eyeOpenClass:"fa-eye",eyeCloseClass:"fa-eye-slash",eyeClassPositionInside:!1};var C=u.fn.password;u.fn.password=function(){var e,t=arguments[0],s=arguments,n=["show","hide","toggle","val","focus"];return this.each((function(){var o=u(this),i=o.data("bs.password"),r=u.extend({},w.DEFAULTS,o.data(),"object"===d(t)&&t);if("string"==typeof t){if(u.inArray(t,n)<0)throw new Error("Unknown method: ".concat(t));e=i[t](s[1])}else i?i.init(r):(i=new w(o,r),o.data("bs.password",i))})),e||this},u.fn.password.Constructor=w,u.fn.password.noConflict=function(){return u.fn.password=C,this},u((function(){u('[data-toggle="password"]').password()}))}));
11 |
--------------------------------------------------------------------------------
/src/bootstrap-show-password.js:
--------------------------------------------------------------------------------
1 | /**
2 | * @author zhixin wen
3 | * https://github.com/wenzhixin/bootstrap-show-password
4 | * version: 1.3.0
5 | */
6 |
7 | let bootstrapVersion = 5
8 |
9 | try {
10 | const rawVersion = $.fn.dropdown.Constructor.VERSION
11 |
12 | // Only try to parse VERSION if it is defined.
13 | // It is undefined in older versions of Bootstrap (tested with 3.1.1).
14 | if (rawVersion !== undefined) {
15 | bootstrapVersion = parseInt(rawVersion, 10)
16 | }
17 | } catch (e) {
18 | // ignore
19 | }
20 |
21 | try {
22 | // eslint-disable-next-line no-undef
23 | const rawVersion = bootstrap.Tooltip.VERSION
24 |
25 | if (rawVersion !== undefined) {
26 | bootstrapVersion = parseInt(rawVersion, 10)
27 | }
28 | } catch (e) {
29 | // ignore
30 | }
31 |
32 | const Constants = {
33 | html: {
34 | inputGroups: {
35 | 3: [
36 | '',
37 | ''
38 | ],
39 | 4: [
40 | ''
42 | ],
43 | 5: [
44 | ''
46 | ]
47 |
48 | }[bootstrapVersion]
49 | }
50 | }
51 |
52 | // TOOLS DEFINITION
53 | // ======================
54 |
55 | // it only does '%s', and return '' when arguments are undefined
56 | const sprintf = function (str) {
57 | const args = arguments
58 | let flag = true
59 | let i = 1
60 |
61 | str = str.replace(/%s/g, () => {
62 | const arg = args[i++]
63 |
64 | if (typeof arg === 'undefined') {
65 | flag = false
66 | return ''
67 | }
68 | return arg
69 | })
70 | if (flag) {
71 | return str
72 | }
73 | return ''
74 | }
75 |
76 | class Password {
77 | constructor (element, options) {
78 | this.options = options
79 | this.$element = $(element)
80 | this.isShown = false
81 |
82 | this.init()
83 | }
84 |
85 | init () {
86 | let placementFuc
87 | let inputClass
88 |
89 | if (this.options.placement === 'before') {
90 | placementFuc = 'insertBefore'
91 | inputClass = 'input-group-prepend'
92 | } else {
93 | this.options.placement = 'after' // default to after
94 | placementFuc = 'insertAfter'
95 | inputClass = 'input-group-append'
96 | }
97 |
98 | // Create the text, icon and assign
99 | this.$element.wrap(``)
100 |
101 | this.$text = $('')[placementFuc](this.$element)
102 | .css('display', this.$element.css('display'))
103 | .val(this.$element.val()).hide()
104 |
105 | for (const attr of this.$element[0].attributes) {
106 | if (
107 | !attr.specified ||
108 | ['id', 'type'].includes(attr.name) ||
109 | attr.name.indexOf('data-') === 0
110 | ) {
111 | continue
112 | }
113 |
114 | this.$text.attr(attr.name, attr.value)
115 | }
116 |
117 | this.$icon = $([
118 | `${sprintf(Constants.html.inputGroups[0], inputClass, this.options.message)}
119 |
120 | ${this.options.eyeClassPositionInside ? this.options.eyeOpenClass : ''}
121 | `,
122 | Constants.html.inputGroups[1]
123 | ].join(''))[placementFuc](this.$text).css('cursor', 'pointer')
124 |
125 | // events
126 | this.$text.off('keyup').on('keyup', $.proxy(function () {
127 | if (!this.isShown) return
128 | this.$element.val(this.$text.val()).trigger('change')
129 | }, this))
130 |
131 | this.$icon.off('click').on('click', $.proxy(function () {
132 | this.$text.val(this.$element.val()).trigger('change')
133 | this.toggle()
134 | }, this))
135 | }
136 |
137 | toggle (_relatedTarget) {
138 | this[!this.isShown ? 'show' : 'hide'](_relatedTarget)
139 | }
140 |
141 | show (_relatedTarget) {
142 | const e = $.Event('show.bs.password', { relatedTarget: _relatedTarget })
143 |
144 | this.$element.trigger(e)
145 |
146 | this.isShown = true
147 | this.$element.hide()
148 | this.$text.show()
149 | if (this.options.eyeClassPositionInside) {
150 | this.$icon.find('i,svg')
151 | .removeClass('icon-eye-open')
152 | .addClass('icon-eye-close')
153 | .html(this.options.eyeCloseClass)
154 | } else {
155 | this.$icon.find('i,svg')
156 | .removeClass(`icon-eye-open ${this.options.eyeOpenClass}`)
157 | .addClass(`icon-eye-close ${this.options.eyeCloseClass}`)
158 | }
159 |
160 | this.$text[this.options.placement](this.$element)
161 | }
162 |
163 | hide (_relatedTarget) {
164 | const e = $.Event('hide.bs.password', { relatedTarget: _relatedTarget })
165 |
166 | this.$element.trigger(e)
167 |
168 | this.isShown = false
169 | this.$element.show()
170 | this.$text.hide()
171 | if (this.options.eyeClassPositionInside) {
172 | this.$icon.find('i,svg')
173 | .removeClass('icon-eye-close')
174 | .addClass('icon-eye-open')
175 | .html(this.options.eyeOpenClass)
176 | } else {
177 | this.$icon.find('i,svg')
178 | .removeClass(`icon-eye-close ${this.options.eyeCloseClass}`)
179 | .addClass(`icon-eye-open ${this.options.eyeOpenClass}`)
180 | }
181 |
182 | this.$element[this.options.placement](this.$text)
183 | }
184 |
185 | val (value) {
186 | if (typeof value === 'undefined') {
187 | return this.$element.val()
188 | }
189 | this.$element.val(value).trigger('change')
190 | this.$text.val(value)
191 |
192 | }
193 |
194 | focus () {
195 | this.$element.focus()
196 | }
197 | }
198 |
199 | Password.DEFAULTS = {
200 | placement: 'after', // 'before' or 'after'
201 | message: 'Click here to show/hide password',
202 | size: undefined, // '', 'sm', 'large'
203 | eyeClass: 'fa', // 'glyphicon',
204 | eyeOpenClass: 'fa-eye', // 'glyphicon-eye-open',
205 | eyeCloseClass: 'fa-eye-slash', // 'glyphicon-eye-close',
206 | eyeClassPositionInside: false
207 | }
208 |
209 | // PASSWORD PLUGIN DEFINITION
210 | // =======================
211 |
212 | const old = $.fn.password
213 |
214 | $.fn.password = function () {
215 | const option = arguments[0] // public function
216 | const args = arguments
217 | let value
218 |
219 | const allowedMethods = [
220 | 'show', 'hide', 'toggle', 'val', 'focus'
221 | ]
222 |
223 | this.each(function () {
224 | const $this = $(this)
225 | let data = $this.data('bs.password')
226 | const options = $.extend({}, Password.DEFAULTS, $this.data(), typeof option === 'object' && option)
227 |
228 | if (typeof option === 'string') {
229 | if ($.inArray(option, allowedMethods) < 0) {
230 | throw new Error(`Unknown method: ${option}`)
231 | }
232 | value = data[option](args[1])
233 | } else if (!data) {
234 | data = new Password($this, options)
235 | $this.data('bs.password', data)
236 | } else {
237 | data.init(options)
238 | }
239 | })
240 |
241 | return value ? value : this
242 | }
243 |
244 | $.fn.password.Constructor = Password
245 |
246 | // PASSWORD NO CONFLICT
247 | // =================
248 |
249 | $.fn.password.noConflict = function () {
250 | $.fn.password = old
251 | return this
252 | }
253 |
254 | $(() => {
255 | $('[data-toggle="password"]').password()
256 | })
257 |
--------------------------------------------------------------------------------
/dist/bootstrap-show-password.esm.js:
--------------------------------------------------------------------------------
1 | import 'core-js/modules/es.array.concat.js';
2 | import 'core-js/modules/es.array.find.js';
3 | import 'core-js/modules/es.array.includes.js';
4 | import 'core-js/modules/es.array.index-of.js';
5 | import 'core-js/modules/es.array.join.js';
6 | import 'core-js/modules/es.function.name.js';
7 | import 'core-js/modules/es.object.to-string.js';
8 | import 'core-js/modules/es.parse-int.js';
9 | import 'core-js/modules/es.regexp.exec.js';
10 | import 'core-js/modules/es.string.replace.js';
11 |
12 | function _toPrimitive(t, r) {
13 | if ("object" != typeof t || !t) return t;
14 | var e = t[Symbol.toPrimitive];
15 | if (void 0 !== e) {
16 | var i = e.call(t, r || "default");
17 | if ("object" != typeof i) return i;
18 | throw new TypeError("@@toPrimitive must return a primitive value.");
19 | }
20 | return ("string" === r ? String : Number)(t);
21 | }
22 | function _toPropertyKey(t) {
23 | var i = _toPrimitive(t, "string");
24 | return "symbol" == typeof i ? i : String(i);
25 | }
26 | function _typeof(o) {
27 | "@babel/helpers - typeof";
28 |
29 | return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) {
30 | return typeof o;
31 | } : function (o) {
32 | return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o;
33 | }, _typeof(o);
34 | }
35 | function _classCallCheck(instance, Constructor) {
36 | if (!(instance instanceof Constructor)) {
37 | throw new TypeError("Cannot call a class as a function");
38 | }
39 | }
40 | function _defineProperties(target, props) {
41 | for (var i = 0; i < props.length; i++) {
42 | var descriptor = props[i];
43 | descriptor.enumerable = descriptor.enumerable || false;
44 | descriptor.configurable = true;
45 | if ("value" in descriptor) descriptor.writable = true;
46 | Object.defineProperty(target, _toPropertyKey(descriptor.key), descriptor);
47 | }
48 | }
49 | function _createClass(Constructor, protoProps, staticProps) {
50 | if (protoProps) _defineProperties(Constructor.prototype, protoProps);
51 | if (staticProps) _defineProperties(Constructor, staticProps);
52 | Object.defineProperty(Constructor, "prototype", {
53 | writable: false
54 | });
55 | return Constructor;
56 | }
57 | function _unsupportedIterableToArray(o, minLen) {
58 | if (!o) return;
59 | if (typeof o === "string") return _arrayLikeToArray(o, minLen);
60 | var n = Object.prototype.toString.call(o).slice(8, -1);
61 | if (n === "Object" && o.constructor) n = o.constructor.name;
62 | if (n === "Map" || n === "Set") return Array.from(o);
63 | if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen);
64 | }
65 | function _arrayLikeToArray(arr, len) {
66 | if (len == null || len > arr.length) len = arr.length;
67 | for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i];
68 | return arr2;
69 | }
70 | function _createForOfIteratorHelper(o, allowArrayLike) {
71 | var it = typeof Symbol !== "undefined" && o[Symbol.iterator] || o["@@iterator"];
72 | if (!it) {
73 | if (Array.isArray(o) || (it = _unsupportedIterableToArray(o)) || allowArrayLike && o && typeof o.length === "number") {
74 | if (it) o = it;
75 | var i = 0;
76 | var F = function () {};
77 | return {
78 | s: F,
79 | n: function () {
80 | if (i >= o.length) return {
81 | done: true
82 | };
83 | return {
84 | done: false,
85 | value: o[i++]
86 | };
87 | },
88 | e: function (e) {
89 | throw e;
90 | },
91 | f: F
92 | };
93 | }
94 | throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
95 | }
96 | var normalCompletion = true,
97 | didErr = false,
98 | err;
99 | return {
100 | s: function () {
101 | it = it.call(o);
102 | },
103 | n: function () {
104 | var step = it.next();
105 | normalCompletion = step.done;
106 | return step;
107 | },
108 | e: function (e) {
109 | didErr = true;
110 | err = e;
111 | },
112 | f: function () {
113 | try {
114 | if (!normalCompletion && it.return != null) it.return();
115 | } finally {
116 | if (didErr) throw err;
117 | }
118 | }
119 | };
120 | }
121 |
122 | /**
123 | * @author zhixin wen
124 | * https://github.com/wenzhixin/bootstrap-show-password
125 | * version: 1.3.0
126 | */
127 |
128 | var bootstrapVersion = 5;
129 | try {
130 | var rawVersion = $.fn.dropdown.Constructor.VERSION;
131 |
132 | // Only try to parse VERSION if it is defined.
133 | // It is undefined in older versions of Bootstrap (tested with 3.1.1).
134 | if (rawVersion !== undefined) {
135 | bootstrapVersion = parseInt(rawVersion, 10);
136 | }
137 | } catch (e) {
138 | // ignore
139 | }
140 | try {
141 | // eslint-disable-next-line no-undef
142 | var _rawVersion = bootstrap.Tooltip.VERSION;
143 | if (_rawVersion !== undefined) {
144 | bootstrapVersion = parseInt(_rawVersion, 10);
145 | }
146 | } catch (e) {
147 | // ignore
148 | }
149 | var Constants = {
150 | html: {
151 | inputGroups: {
152 | 3: ['', ''],
153 | 4: [''],
154 | 5: ['']
155 | }[bootstrapVersion]
156 | }
157 | };
158 |
159 | // TOOLS DEFINITION
160 | // ======================
161 |
162 | // it only does '%s', and return '' when arguments are undefined
163 | var sprintf = function sprintf(str) {
164 | var args = arguments;
165 | var flag = true;
166 | var i = 1;
167 | str = str.replace(/%s/g, function () {
168 | var arg = args[i++];
169 | if (typeof arg === 'undefined') {
170 | flag = false;
171 | return '';
172 | }
173 | return arg;
174 | });
175 | if (flag) {
176 | return str;
177 | }
178 | return '';
179 | };
180 | var Password = /*#__PURE__*/function () {
181 | function Password(element, options) {
182 | _classCallCheck(this, Password);
183 | this.options = options;
184 | this.$element = $(element);
185 | this.isShown = false;
186 | this.init();
187 | }
188 | _createClass(Password, [{
189 | key: "init",
190 | value: function init() {
191 | var placementFuc;
192 | var inputClass;
193 | if (this.options.placement === 'before') {
194 | placementFuc = 'insertBefore';
195 | inputClass = 'input-group-prepend';
196 | } else {
197 | this.options.placement = 'after'; // default to after
198 | placementFuc = 'insertAfter';
199 | inputClass = 'input-group-append';
200 | }
201 |
202 | // Create the text, icon and assign
203 | this.$element.wrap(""));
204 | this.$text = $('')[placementFuc](this.$element).css('display', this.$element.css('display')).val(this.$element.val()).hide();
205 | var _iterator = _createForOfIteratorHelper(this.$element[0].attributes),
206 | _step;
207 | try {
208 | for (_iterator.s(); !(_step = _iterator.n()).done;) {
209 | var attr = _step.value;
210 | if (!attr.specified || ['id', 'type'].includes(attr.name) || attr.name.indexOf('data-') === 0) {
211 | continue;
212 | }
213 | this.$text.attr(attr.name, attr.value);
214 | }
215 | } catch (err) {
216 | _iterator.e(err);
217 | } finally {
218 | _iterator.f();
219 | }
220 | this.$icon = $(["".concat(sprintf(Constants.html.inputGroups[0], inputClass, this.options.message), "\n \n ").concat(this.options.eyeClassPositionInside ? this.options.eyeOpenClass : '', "\n "), Constants.html.inputGroups[1]].join(''))[placementFuc](this.$text).css('cursor', 'pointer');
221 |
222 | // events
223 | this.$text.off('keyup').on('keyup', $.proxy(function () {
224 | if (!this.isShown) return;
225 | this.$element.val(this.$text.val()).trigger('change');
226 | }, this));
227 | this.$icon.off('click').on('click', $.proxy(function () {
228 | this.$text.val(this.$element.val()).trigger('change');
229 | this.toggle();
230 | }, this));
231 | }
232 | }, {
233 | key: "toggle",
234 | value: function toggle(_relatedTarget) {
235 | this[!this.isShown ? 'show' : 'hide'](_relatedTarget);
236 | }
237 | }, {
238 | key: "show",
239 | value: function show(_relatedTarget) {
240 | var e = $.Event('show.bs.password', {
241 | relatedTarget: _relatedTarget
242 | });
243 | this.$element.trigger(e);
244 | this.isShown = true;
245 | this.$element.hide();
246 | this.$text.show();
247 | if (this.options.eyeClassPositionInside) {
248 | this.$icon.find('i,svg').removeClass('icon-eye-open').addClass('icon-eye-close').html(this.options.eyeCloseClass);
249 | } else {
250 | this.$icon.find('i,svg').removeClass("icon-eye-open ".concat(this.options.eyeOpenClass)).addClass("icon-eye-close ".concat(this.options.eyeCloseClass));
251 | }
252 | this.$text[this.options.placement](this.$element);
253 | }
254 | }, {
255 | key: "hide",
256 | value: function hide(_relatedTarget) {
257 | var e = $.Event('hide.bs.password', {
258 | relatedTarget: _relatedTarget
259 | });
260 | this.$element.trigger(e);
261 | this.isShown = false;
262 | this.$element.show();
263 | this.$text.hide();
264 | if (this.options.eyeClassPositionInside) {
265 | this.$icon.find('i,svg').removeClass('icon-eye-close').addClass('icon-eye-open').html(this.options.eyeOpenClass);
266 | } else {
267 | this.$icon.find('i,svg').removeClass("icon-eye-close ".concat(this.options.eyeCloseClass)).addClass("icon-eye-open ".concat(this.options.eyeOpenClass));
268 | }
269 | this.$element[this.options.placement](this.$text);
270 | }
271 | }, {
272 | key: "val",
273 | value: function val(value) {
274 | if (typeof value === 'undefined') {
275 | return this.$element.val();
276 | }
277 | this.$element.val(value).trigger('change');
278 | this.$text.val(value);
279 | }
280 | }, {
281 | key: "focus",
282 | value: function focus() {
283 | this.$element.focus();
284 | }
285 | }]);
286 | return Password;
287 | }();
288 | Password.DEFAULTS = {
289 | placement: 'after',
290 | // 'before' or 'after'
291 | message: 'Click here to show/hide password',
292 | size: undefined,
293 | // '', 'sm', 'large'
294 | eyeClass: 'fa',
295 | // 'glyphicon',
296 | eyeOpenClass: 'fa-eye',
297 | // 'glyphicon-eye-open',
298 | eyeCloseClass: 'fa-eye-slash',
299 | // 'glyphicon-eye-close',
300 | eyeClassPositionInside: false
301 | };
302 |
303 | // PASSWORD PLUGIN DEFINITION
304 | // =======================
305 |
306 | var old = $.fn.password;
307 | $.fn.password = function () {
308 | var option = arguments[0]; // public function
309 | var args = arguments;
310 | var value;
311 | var allowedMethods = ['show', 'hide', 'toggle', 'val', 'focus'];
312 | this.each(function () {
313 | var $this = $(this);
314 | var data = $this.data('bs.password');
315 | var options = $.extend({}, Password.DEFAULTS, $this.data(), _typeof(option) === 'object' && option);
316 | if (typeof option === 'string') {
317 | if ($.inArray(option, allowedMethods) < 0) {
318 | throw new Error("Unknown method: ".concat(option));
319 | }
320 | value = data[option](args[1]);
321 | } else if (!data) {
322 | data = new Password($this, options);
323 | $this.data('bs.password', data);
324 | } else {
325 | data.init(options);
326 | }
327 | });
328 | return value ? value : this;
329 | };
330 | $.fn.password.Constructor = Password;
331 |
332 | // PASSWORD NO CONFLICT
333 | // =================
334 |
335 | $.fn.password.noConflict = function () {
336 | $.fn.password = old;
337 | return this;
338 | };
339 | $(function () {
340 | $('[data-toggle="password"]').password();
341 | });
342 |
--------------------------------------------------------------------------------
/dist/bootstrap-show-password.js:
--------------------------------------------------------------------------------
1 | (function (global, factory) {
2 | typeof exports === 'object' && typeof module !== 'undefined' ? factory(require('core-js/modules/es.array.concat.js'), require('core-js/modules/es.array.find.js'), require('core-js/modules/es.array.includes.js'), require('core-js/modules/es.array.index-of.js'), require('core-js/modules/es.array.join.js'), require('core-js/modules/es.function.name.js'), require('core-js/modules/es.object.to-string.js'), require('core-js/modules/es.parse-int.js'), require('core-js/modules/es.regexp.exec.js'), require('core-js/modules/es.string.replace.js'), require('jquery')) :
3 | typeof define === 'function' && define.amd ? define(['core-js/modules/es.array.concat.js', 'core-js/modules/es.array.find.js', 'core-js/modules/es.array.includes.js', 'core-js/modules/es.array.index-of.js', 'core-js/modules/es.array.join.js', 'core-js/modules/es.function.name.js', 'core-js/modules/es.object.to-string.js', 'core-js/modules/es.parse-int.js', 'core-js/modules/es.regexp.exec.js', 'core-js/modules/es.string.replace.js', 'jquery'], factory) :
4 | (global = typeof globalThis !== 'undefined' ? globalThis : global || self, factory(null, null, null, null, null, null, null, null, null, null, global.jQuery));
5 | })(this, (function (es_array_concat_js, es_array_find_js, es_array_includes_js, es_array_indexOf_js, es_array_join_js, es_function_name_js, es_object_toString_js, es_parseInt_js, es_regexp_exec_js, es_string_replace_js, $) { 'use strict';
6 |
7 | function _toPrimitive(t, r) {
8 | if ("object" != typeof t || !t) return t;
9 | var e = t[Symbol.toPrimitive];
10 | if (void 0 !== e) {
11 | var i = e.call(t, r || "default");
12 | if ("object" != typeof i) return i;
13 | throw new TypeError("@@toPrimitive must return a primitive value.");
14 | }
15 | return ("string" === r ? String : Number)(t);
16 | }
17 | function _toPropertyKey(t) {
18 | var i = _toPrimitive(t, "string");
19 | return "symbol" == typeof i ? i : String(i);
20 | }
21 | function _typeof(o) {
22 | "@babel/helpers - typeof";
23 |
24 | return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) {
25 | return typeof o;
26 | } : function (o) {
27 | return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o;
28 | }, _typeof(o);
29 | }
30 | function _classCallCheck(instance, Constructor) {
31 | if (!(instance instanceof Constructor)) {
32 | throw new TypeError("Cannot call a class as a function");
33 | }
34 | }
35 | function _defineProperties(target, props) {
36 | for (var i = 0; i < props.length; i++) {
37 | var descriptor = props[i];
38 | descriptor.enumerable = descriptor.enumerable || false;
39 | descriptor.configurable = true;
40 | if ("value" in descriptor) descriptor.writable = true;
41 | Object.defineProperty(target, _toPropertyKey(descriptor.key), descriptor);
42 | }
43 | }
44 | function _createClass(Constructor, protoProps, staticProps) {
45 | if (protoProps) _defineProperties(Constructor.prototype, protoProps);
46 | if (staticProps) _defineProperties(Constructor, staticProps);
47 | Object.defineProperty(Constructor, "prototype", {
48 | writable: false
49 | });
50 | return Constructor;
51 | }
52 | function _unsupportedIterableToArray(o, minLen) {
53 | if (!o) return;
54 | if (typeof o === "string") return _arrayLikeToArray(o, minLen);
55 | var n = Object.prototype.toString.call(o).slice(8, -1);
56 | if (n === "Object" && o.constructor) n = o.constructor.name;
57 | if (n === "Map" || n === "Set") return Array.from(o);
58 | if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen);
59 | }
60 | function _arrayLikeToArray(arr, len) {
61 | if (len == null || len > arr.length) len = arr.length;
62 | for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i];
63 | return arr2;
64 | }
65 | function _createForOfIteratorHelper(o, allowArrayLike) {
66 | var it = typeof Symbol !== "undefined" && o[Symbol.iterator] || o["@@iterator"];
67 | if (!it) {
68 | if (Array.isArray(o) || (it = _unsupportedIterableToArray(o)) || allowArrayLike && o && typeof o.length === "number") {
69 | if (it) o = it;
70 | var i = 0;
71 | var F = function () {};
72 | return {
73 | s: F,
74 | n: function () {
75 | if (i >= o.length) return {
76 | done: true
77 | };
78 | return {
79 | done: false,
80 | value: o[i++]
81 | };
82 | },
83 | e: function (e) {
84 | throw e;
85 | },
86 | f: F
87 | };
88 | }
89 | throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
90 | }
91 | var normalCompletion = true,
92 | didErr = false,
93 | err;
94 | return {
95 | s: function () {
96 | it = it.call(o);
97 | },
98 | n: function () {
99 | var step = it.next();
100 | normalCompletion = step.done;
101 | return step;
102 | },
103 | e: function (e) {
104 | didErr = true;
105 | err = e;
106 | },
107 | f: function () {
108 | try {
109 | if (!normalCompletion && it.return != null) it.return();
110 | } finally {
111 | if (didErr) throw err;
112 | }
113 | }
114 | };
115 | }
116 |
117 | /**
118 | * @author zhixin wen
119 | * https://github.com/wenzhixin/bootstrap-show-password
120 | * version: 1.3.0
121 | */
122 |
123 | var bootstrapVersion = 5;
124 | try {
125 | var rawVersion = $.fn.dropdown.Constructor.VERSION;
126 |
127 | // Only try to parse VERSION if it is defined.
128 | // It is undefined in older versions of Bootstrap (tested with 3.1.1).
129 | if (rawVersion !== undefined) {
130 | bootstrapVersion = parseInt(rawVersion, 10);
131 | }
132 | } catch (e) {
133 | // ignore
134 | }
135 | try {
136 | // eslint-disable-next-line no-undef
137 | var _rawVersion = bootstrap.Tooltip.VERSION;
138 | if (_rawVersion !== undefined) {
139 | bootstrapVersion = parseInt(_rawVersion, 10);
140 | }
141 | } catch (e) {
142 | // ignore
143 | }
144 | var Constants = {
145 | html: {
146 | inputGroups: {
147 | 3: ['', ''],
148 | 4: [''],
149 | 5: ['']
150 | }[bootstrapVersion]
151 | }
152 | };
153 |
154 | // TOOLS DEFINITION
155 | // ======================
156 |
157 | // it only does '%s', and return '' when arguments are undefined
158 | var sprintf = function sprintf(str) {
159 | var args = arguments;
160 | var flag = true;
161 | var i = 1;
162 | str = str.replace(/%s/g, function () {
163 | var arg = args[i++];
164 | if (typeof arg === 'undefined') {
165 | flag = false;
166 | return '';
167 | }
168 | return arg;
169 | });
170 | if (flag) {
171 | return str;
172 | }
173 | return '';
174 | };
175 | var Password = /*#__PURE__*/function () {
176 | function Password(element, options) {
177 | _classCallCheck(this, Password);
178 | this.options = options;
179 | this.$element = $(element);
180 | this.isShown = false;
181 | this.init();
182 | }
183 | _createClass(Password, [{
184 | key: "init",
185 | value: function init() {
186 | var placementFuc;
187 | var inputClass;
188 | if (this.options.placement === 'before') {
189 | placementFuc = 'insertBefore';
190 | inputClass = 'input-group-prepend';
191 | } else {
192 | this.options.placement = 'after'; // default to after
193 | placementFuc = 'insertAfter';
194 | inputClass = 'input-group-append';
195 | }
196 |
197 | // Create the text, icon and assign
198 | this.$element.wrap(""));
199 | this.$text = $('')[placementFuc](this.$element).css('display', this.$element.css('display')).val(this.$element.val()).hide();
200 | var _iterator = _createForOfIteratorHelper(this.$element[0].attributes),
201 | _step;
202 | try {
203 | for (_iterator.s(); !(_step = _iterator.n()).done;) {
204 | var attr = _step.value;
205 | if (!attr.specified || ['id', 'type'].includes(attr.name) || attr.name.indexOf('data-') === 0) {
206 | continue;
207 | }
208 | this.$text.attr(attr.name, attr.value);
209 | }
210 | } catch (err) {
211 | _iterator.e(err);
212 | } finally {
213 | _iterator.f();
214 | }
215 | this.$icon = $(["".concat(sprintf(Constants.html.inputGroups[0], inputClass, this.options.message), "\n \n ").concat(this.options.eyeClassPositionInside ? this.options.eyeOpenClass : '', "\n "), Constants.html.inputGroups[1]].join(''))[placementFuc](this.$text).css('cursor', 'pointer');
216 |
217 | // events
218 | this.$text.off('keyup').on('keyup', $.proxy(function () {
219 | if (!this.isShown) return;
220 | this.$element.val(this.$text.val()).trigger('change');
221 | }, this));
222 | this.$icon.off('click').on('click', $.proxy(function () {
223 | this.$text.val(this.$element.val()).trigger('change');
224 | this.toggle();
225 | }, this));
226 | }
227 | }, {
228 | key: "toggle",
229 | value: function toggle(_relatedTarget) {
230 | this[!this.isShown ? 'show' : 'hide'](_relatedTarget);
231 | }
232 | }, {
233 | key: "show",
234 | value: function show(_relatedTarget) {
235 | var e = $.Event('show.bs.password', {
236 | relatedTarget: _relatedTarget
237 | });
238 | this.$element.trigger(e);
239 | this.isShown = true;
240 | this.$element.hide();
241 | this.$text.show();
242 | if (this.options.eyeClassPositionInside) {
243 | this.$icon.find('i,svg').removeClass('icon-eye-open').addClass('icon-eye-close').html(this.options.eyeCloseClass);
244 | } else {
245 | this.$icon.find('i,svg').removeClass("icon-eye-open ".concat(this.options.eyeOpenClass)).addClass("icon-eye-close ".concat(this.options.eyeCloseClass));
246 | }
247 | this.$text[this.options.placement](this.$element);
248 | }
249 | }, {
250 | key: "hide",
251 | value: function hide(_relatedTarget) {
252 | var e = $.Event('hide.bs.password', {
253 | relatedTarget: _relatedTarget
254 | });
255 | this.$element.trigger(e);
256 | this.isShown = false;
257 | this.$element.show();
258 | this.$text.hide();
259 | if (this.options.eyeClassPositionInside) {
260 | this.$icon.find('i,svg').removeClass('icon-eye-close').addClass('icon-eye-open').html(this.options.eyeOpenClass);
261 | } else {
262 | this.$icon.find('i,svg').removeClass("icon-eye-close ".concat(this.options.eyeCloseClass)).addClass("icon-eye-open ".concat(this.options.eyeOpenClass));
263 | }
264 | this.$element[this.options.placement](this.$text);
265 | }
266 | }, {
267 | key: "val",
268 | value: function val(value) {
269 | if (typeof value === 'undefined') {
270 | return this.$element.val();
271 | }
272 | this.$element.val(value).trigger('change');
273 | this.$text.val(value);
274 | }
275 | }, {
276 | key: "focus",
277 | value: function focus() {
278 | this.$element.focus();
279 | }
280 | }]);
281 | return Password;
282 | }();
283 | Password.DEFAULTS = {
284 | placement: 'after',
285 | // 'before' or 'after'
286 | message: 'Click here to show/hide password',
287 | size: undefined,
288 | // '', 'sm', 'large'
289 | eyeClass: 'fa',
290 | // 'glyphicon',
291 | eyeOpenClass: 'fa-eye',
292 | // 'glyphicon-eye-open',
293 | eyeCloseClass: 'fa-eye-slash',
294 | // 'glyphicon-eye-close',
295 | eyeClassPositionInside: false
296 | };
297 |
298 | // PASSWORD PLUGIN DEFINITION
299 | // =======================
300 |
301 | var old = $.fn.password;
302 | $.fn.password = function () {
303 | var option = arguments[0]; // public function
304 | var args = arguments;
305 | var value;
306 | var allowedMethods = ['show', 'hide', 'toggle', 'val', 'focus'];
307 | this.each(function () {
308 | var $this = $(this);
309 | var data = $this.data('bs.password');
310 | var options = $.extend({}, Password.DEFAULTS, $this.data(), _typeof(option) === 'object' && option);
311 | if (typeof option === 'string') {
312 | if ($.inArray(option, allowedMethods) < 0) {
313 | throw new Error("Unknown method: ".concat(option));
314 | }
315 | value = data[option](args[1]);
316 | } else if (!data) {
317 | data = new Password($this, options);
318 | $this.data('bs.password', data);
319 | } else {
320 | data.init(options);
321 | }
322 | });
323 | return value ? value : this;
324 | };
325 | $.fn.password.Constructor = Password;
326 |
327 | // PASSWORD NO CONFLICT
328 | // =================
329 |
330 | $.fn.password.noConflict = function () {
331 | $.fn.password = old;
332 | return this;
333 | };
334 | $(function () {
335 | $('[data-toggle="password"]').password();
336 | });
337 |
338 | }));
339 |
--------------------------------------------------------------------------------
/docs/LICENSE:
--------------------------------------------------------------------------------
1 | Creative Commons Legal Code
2 |
3 | Attribution 3.0 Unported
4 |
5 | CREATIVE COMMONS CORPORATION IS NOT A LAW FIRM AND DOES NOT PROVIDE
6 | LEGAL SERVICES. DISTRIBUTION OF THIS LICENSE DOES NOT CREATE AN
7 | ATTORNEY-CLIENT RELATIONSHIP. CREATIVE COMMONS PROVIDES THIS
8 | INFORMATION ON AN "AS-IS" BASIS. CREATIVE COMMONS MAKES NO WARRANTIES
9 | REGARDING THE INFORMATION PROVIDED, AND DISCLAIMS LIABILITY FOR
10 | DAMAGES RESULTING FROM ITS USE.
11 |
12 | License
13 |
14 | THE WORK (AS DEFINED BELOW) IS PROVIDED UNDER THE TERMS OF THIS CREATIVE
15 | COMMONS PUBLIC LICENSE ("CCPL" OR "LICENSE"). THE WORK IS PROTECTED BY
16 | COPYRIGHT AND/OR OTHER APPLICABLE LAW. ANY USE OF THE WORK OTHER THAN AS
17 | AUTHORIZED UNDER THIS LICENSE OR COPYRIGHT LAW IS PROHIBITED.
18 |
19 | BY EXERCISING ANY RIGHTS TO THE WORK PROVIDED HERE, YOU ACCEPT AND AGREE
20 | TO BE BOUND BY THE TERMS OF THIS LICENSE. TO THE EXTENT THIS LICENSE MAY
21 | BE CONSIDERED TO BE A CONTRACT, THE LICENSOR GRANTS YOU THE RIGHTS
22 | CONTAINED HERE IN CONSIDERATION OF YOUR ACCEPTANCE OF SUCH TERMS AND
23 | CONDITIONS.
24 |
25 | 1. Definitions
26 |
27 | a. "Adaptation" means a work based upon the Work, or upon the Work and
28 | other pre-existing works, such as a translation, adaptation,
29 | derivative work, arrangement of music or other alterations of a
30 | literary or artistic work, or phonogram or performance and includes
31 | cinematographic adaptations or any other form in which the Work may be
32 | recast, transformed, or adapted including in any form recognizably
33 | derived from the original, except that a work that constitutes a
34 | Collection will not be considered an Adaptation for the purpose of
35 | this License. For the avoidance of doubt, where the Work is a musical
36 | work, performance or phonogram, the synchronization of the Work in
37 | timed-relation with a moving image ("synching") will be considered an
38 | Adaptation for the purpose of this License.
39 | b. "Collection" means a collection of literary or artistic works, such as
40 | encyclopedias and anthologies, or performances, phonograms or
41 | broadcasts, or other works or subject matter other than works listed
42 | in Section 1(f) below, which, by reason of the selection and
43 | arrangement of their contents, constitute intellectual creations, in
44 | which the Work is included in its entirety in unmodified form along
45 | with one or more other contributions, each constituting separate and
46 | independent works in themselves, which together are assembled into a
47 | collective whole. A work that constitutes a Collection will not be
48 | considered an Adaptation (as defined above) for the purposes of this
49 | License.
50 | c. "Distribute" means to make available to the public the original and
51 | copies of the Work or Adaptation, as appropriate, through sale or
52 | other transfer of ownership.
53 | d. "Licensor" means the individual, individuals, entity or entities that
54 | offer(s) the Work under the terms of this License.
55 | e. "Original Author" means, in the case of a literary or artistic work,
56 | the individual, individuals, entity or entities who created the Work
57 | or if no individual or entity can be identified, the publisher; and in
58 | addition (i) in the case of a performance the actors, singers,
59 | musicians, dancers, and other persons who act, sing, deliver, declaim,
60 | play in, interpret or otherwise perform literary or artistic works or
61 | expressions of folklore; (ii) in the case of a phonogram the producer
62 | being the person or legal entity who first fixes the sounds of a
63 | performance or other sounds; and, (iii) in the case of broadcasts, the
64 | organization that transmits the broadcast.
65 | f. "Work" means the literary and/or artistic work offered under the terms
66 | of this License including without limitation any production in the
67 | literary, scientific and artistic domain, whatever may be the mode or
68 | form of its expression including digital form, such as a book,
69 | pamphlet and other writing; a lecture, address, sermon or other work
70 | of the same nature; a dramatic or dramatico-musical work; a
71 | choreographic work or entertainment in dumb show; a musical
72 | composition with or without words; a cinematographic work to which are
73 | assimilated works expressed by a process analogous to cinematography;
74 | a work of drawing, painting, architecture, sculpture, engraving or
75 | lithography; a photographic work to which are assimilated works
76 | expressed by a process analogous to photography; a work of applied
77 | art; an illustration, map, plan, sketch or three-dimensional work
78 | relative to geography, topography, architecture or science; a
79 | performance; a broadcast; a phonogram; a compilation of data to the
80 | extent it is protected as a copyrightable work; or a work performed by
81 | a variety or circus performer to the extent it is not otherwise
82 | considered a literary or artistic work.
83 | g. "You" means an individual or entity exercising rights under this
84 | License who has not previously violated the terms of this License with
85 | respect to the Work, or who has received express permission from the
86 | Licensor to exercise rights under this License despite a previous
87 | violation.
88 | h. "Publicly Perform" means to perform public recitations of the Work and
89 | to communicate to the public those public recitations, by any means or
90 | process, including by wire or wireless means or public digital
91 | performances; to make available to the public Works in such a way that
92 | members of the public may access these Works from a place and at a
93 | place individually chosen by them; to perform the Work to the public
94 | by any means or process and the communication to the public of the
95 | performances of the Work, including by public digital performance; to
96 | broadcast and rebroadcast the Work by any means including signs,
97 | sounds or images.
98 | i. "Reproduce" means to make copies of the Work by any means including
99 | without limitation by sound or visual recordings and the right of
100 | fixation and reproducing fixations of the Work, including storage of a
101 | protected performance or phonogram in digital form or other electronic
102 | medium.
103 |
104 | 2. Fair Dealing Rights. Nothing in this License is intended to reduce,
105 | limit, or restrict any uses free from copyright or rights arising from
106 | limitations or exceptions that are provided for in connection with the
107 | copyright protection under copyright law or other applicable laws.
108 |
109 | 3. License Grant. Subject to the terms and conditions of this License,
110 | Licensor hereby grants You a worldwide, royalty-free, non-exclusive,
111 | perpetual (for the duration of the applicable copyright) license to
112 | exercise the rights in the Work as stated below:
113 |
114 | a. to Reproduce the Work, to incorporate the Work into one or more
115 | Collections, and to Reproduce the Work as incorporated in the
116 | Collections;
117 | b. to create and Reproduce Adaptations provided that any such Adaptation,
118 | including any translation in any medium, takes reasonable steps to
119 | clearly label, demarcate or otherwise identify that changes were made
120 | to the original Work. For example, a translation could be marked "The
121 | original work was translated from English to Spanish," or a
122 | modification could indicate "The original work has been modified.";
123 | c. to Distribute and Publicly Perform the Work including as incorporated
124 | in Collections; and,
125 | d. to Distribute and Publicly Perform Adaptations.
126 | e. For the avoidance of doubt:
127 |
128 | i. Non-waivable Compulsory License Schemes. In those jurisdictions in
129 | which the right to collect royalties through any statutory or
130 | compulsory licensing scheme cannot be waived, the Licensor
131 | reserves the exclusive right to collect such royalties for any
132 | exercise by You of the rights granted under this License;
133 | ii. Waivable Compulsory License Schemes. In those jurisdictions in
134 | which the right to collect royalties through any statutory or
135 | compulsory licensing scheme can be waived, the Licensor waives the
136 | exclusive right to collect such royalties for any exercise by You
137 | of the rights granted under this License; and,
138 | iii. Voluntary License Schemes. The Licensor waives the right to
139 | collect royalties, whether individually or, in the event that the
140 | Licensor is a member of a collecting society that administers
141 | voluntary licensing schemes, via that society, from any exercise
142 | by You of the rights granted under this License.
143 |
144 | The above rights may be exercised in all media and formats whether now
145 | known or hereafter devised. The above rights include the right to make
146 | such modifications as are technically necessary to exercise the rights in
147 | other media and formats. Subject to Section 8(f), all rights not expressly
148 | granted by Licensor are hereby reserved.
149 |
150 | 4. Restrictions. The license granted in Section 3 above is expressly made
151 | subject to and limited by the following restrictions:
152 |
153 | a. You may Distribute or Publicly Perform the Work only under the terms
154 | of this License. You must include a copy of, or the Uniform Resource
155 | Identifier (URI) for, this License with every copy of the Work You
156 | Distribute or Publicly Perform. You may not offer or impose any terms
157 | on the Work that restrict the terms of this License or the ability of
158 | the recipient of the Work to exercise the rights granted to that
159 | recipient under the terms of the License. You may not sublicense the
160 | Work. You must keep intact all notices that refer to this License and
161 | to the disclaimer of warranties with every copy of the Work You
162 | Distribute or Publicly Perform. When You Distribute or Publicly
163 | Perform the Work, You may not impose any effective technological
164 | measures on the Work that restrict the ability of a recipient of the
165 | Work from You to exercise the rights granted to that recipient under
166 | the terms of the License. This Section 4(a) applies to the Work as
167 | incorporated in a Collection, but this does not require the Collection
168 | apart from the Work itself to be made subject to the terms of this
169 | License. If You create a Collection, upon notice from any Licensor You
170 | must, to the extent practicable, remove from the Collection any credit
171 | as required by Section 4(b), as requested. If You create an
172 | Adaptation, upon notice from any Licensor You must, to the extent
173 | practicable, remove from the Adaptation any credit as required by
174 | Section 4(b), as requested.
175 | b. If You Distribute, or Publicly Perform the Work or any Adaptations or
176 | Collections, You must, unless a request has been made pursuant to
177 | Section 4(a), keep intact all copyright notices for the Work and
178 | provide, reasonable to the medium or means You are utilizing: (i) the
179 | name of the Original Author (or pseudonym, if applicable) if supplied,
180 | and/or if the Original Author and/or Licensor designate another party
181 | or parties (e.g., a sponsor institute, publishing entity, journal) for
182 | attribution ("Attribution Parties") in Licensor's copyright notice,
183 | terms of service or by other reasonable means, the name of such party
184 | or parties; (ii) the title of the Work if supplied; (iii) to the
185 | extent reasonably practicable, the URI, if any, that Licensor
186 | specifies to be associated with the Work, unless such URI does not
187 | refer to the copyright notice or licensing information for the Work;
188 | and (iv) , consistent with Section 3(b), in the case of an Adaptation,
189 | a credit identifying the use of the Work in the Adaptation (e.g.,
190 | "French translation of the Work by Original Author," or "Screenplay
191 | based on original Work by Original Author"). The credit required by
192 | this Section 4 (b) may be implemented in any reasonable manner;
193 | provided, however, that in the case of a Adaptation or Collection, at
194 | a minimum such credit will appear, if a credit for all contributing
195 | authors of the Adaptation or Collection appears, then as part of these
196 | credits and in a manner at least as prominent as the credits for the
197 | other contributing authors. For the avoidance of doubt, You may only
198 | use the credit required by this Section for the purpose of attribution
199 | in the manner set out above and, by exercising Your rights under this
200 | License, You may not implicitly or explicitly assert or imply any
201 | connection with, sponsorship or endorsement by the Original Author,
202 | Licensor and/or Attribution Parties, as appropriate, of You or Your
203 | use of the Work, without the separate, express prior written
204 | permission of the Original Author, Licensor and/or Attribution
205 | Parties.
206 | c. Except as otherwise agreed in writing by the Licensor or as may be
207 | otherwise permitted by applicable law, if You Reproduce, Distribute or
208 | Publicly Perform the Work either by itself or as part of any
209 | Adaptations or Collections, You must not distort, mutilate, modify or
210 | take other derogatory action in relation to the Work which would be
211 | prejudicial to the Original Author's honor or reputation. Licensor
212 | agrees that in those jurisdictions (e.g. Japan), in which any exercise
213 | of the right granted in Section 3(b) of this License (the right to
214 | make Adaptations) would be deemed to be a distortion, mutilation,
215 | modification or other derogatory action prejudicial to the Original
216 | Author's honor and reputation, the Licensor will waive or not assert,
217 | as appropriate, this Section, to the fullest extent permitted by the
218 | applicable national law, to enable You to reasonably exercise Your
219 | right under Section 3(b) of this License (right to make Adaptations)
220 | but not otherwise.
221 |
222 | 5. Representations, Warranties and Disclaimer
223 |
224 | UNLESS OTHERWISE MUTUALLY AGREED TO BY THE PARTIES IN WRITING, LICENSOR
225 | OFFERS THE WORK AS-IS AND MAKES NO REPRESENTATIONS OR WARRANTIES OF ANY
226 | KIND CONCERNING THE WORK, EXPRESS, IMPLIED, STATUTORY OR OTHERWISE,
227 | INCLUDING, WITHOUT LIMITATION, WARRANTIES OF TITLE, MERCHANTIBILITY,
228 | FITNESS FOR A PARTICULAR PURPOSE, NONINFRINGEMENT, OR THE ABSENCE OF
229 | LATENT OR OTHER DEFECTS, ACCURACY, OR THE PRESENCE OF ABSENCE OF ERRORS,
230 | WHETHER OR NOT DISCOVERABLE. SOME JURISDICTIONS DO NOT ALLOW THE EXCLUSION
231 | OF IMPLIED WARRANTIES, SO SUCH EXCLUSION MAY NOT APPLY TO YOU.
232 |
233 | 6. Limitation on Liability. EXCEPT TO THE EXTENT REQUIRED BY APPLICABLE
234 | LAW, IN NO EVENT WILL LICENSOR BE LIABLE TO YOU ON ANY LEGAL THEORY FOR
235 | ANY SPECIAL, INCIDENTAL, CONSEQUENTIAL, PUNITIVE OR EXEMPLARY DAMAGES
236 | ARISING OUT OF THIS LICENSE OR THE USE OF THE WORK, EVEN IF LICENSOR HAS
237 | BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.
238 |
239 | 7. Termination
240 |
241 | a. This License and the rights granted hereunder will terminate
242 | automatically upon any breach by You of the terms of this License.
243 | Individuals or entities who have received Adaptations or Collections
244 | from You under this License, however, will not have their licenses
245 | terminated provided such individuals or entities remain in full
246 | compliance with those licenses. Sections 1, 2, 5, 6, 7, and 8 will
247 | survive any termination of this License.
248 | b. Subject to the above terms and conditions, the license granted here is
249 | perpetual (for the duration of the applicable copyright in the Work).
250 | Notwithstanding the above, Licensor reserves the right to release the
251 | Work under different license terms or to stop distributing the Work at
252 | any time; provided, however that any such election will not serve to
253 | withdraw this License (or any other license that has been, or is
254 | required to be, granted under the terms of this License), and this
255 | License will continue in full force and effect unless terminated as
256 | stated above.
257 |
258 | 8. Miscellaneous
259 |
260 | a. Each time You Distribute or Publicly Perform the Work or a Collection,
261 | the Licensor offers to the recipient a license to the Work on the same
262 | terms and conditions as the license granted to You under this License.
263 | b. Each time You Distribute or Publicly Perform an Adaptation, Licensor
264 | offers to the recipient a license to the original Work on the same
265 | terms and conditions as the license granted to You under this License.
266 | c. If any provision of this License is invalid or unenforceable under
267 | applicable law, it shall not affect the validity or enforceability of
268 | the remainder of the terms of this License, and without further action
269 | by the parties to this agreement, such provision shall be reformed to
270 | the minimum extent necessary to make such provision valid and
271 | enforceable.
272 | d. No term or provision of this License shall be deemed waived and no
273 | breach consented to unless such waiver or consent shall be in writing
274 | and signed by the party to be charged with such waiver or consent.
275 | e. This License constitutes the entire agreement between the parties with
276 | respect to the Work licensed here. There are no understandings,
277 | agreements or representations with respect to the Work not specified
278 | here. Licensor shall not be bound by any additional provisions that
279 | may appear in any communication from You. This License may not be
280 | modified without the mutual written agreement of the Licensor and You.
281 | f. The rights granted under, and the subject matter referenced, in this
282 | License were drafted utilizing the terminology of the Berne Convention
283 | for the Protection of Literary and Artistic Works (as amended on
284 | September 28, 1979), the Rome Convention of 1961, the WIPO Copyright
285 | Treaty of 1996, the WIPO Performances and Phonograms Treaty of 1996
286 | and the Universal Copyright Convention (as revised on July 24, 1971).
287 | These rights and subject matter take effect in the relevant
288 | jurisdiction in which the License terms are sought to be enforced
289 | according to the corresponding provisions of the implementation of
290 | those treaty provisions in the applicable national law. If the
291 | standard suite of rights granted under applicable copyright law
292 | includes additional rights not granted under this License, such
293 | additional rights are deemed to be included in the License; this
294 | License is not intended to restrict the license of any rights under
295 | applicable law.
296 |
297 |
298 | Creative Commons Notice
299 |
300 | Creative Commons is not a party to this License, and makes no warranty
301 | whatsoever in connection with the Work. Creative Commons will not be
302 | liable to You or any party on any legal theory for any damages
303 | whatsoever, including without limitation any general, special,
304 | incidental or consequential damages arising in connection to this
305 | license. Notwithstanding the foregoing two (2) sentences, if Creative
306 | Commons has expressly identified itself as the Licensor hereunder, it
307 | shall have all rights and obligations of Licensor.
308 |
309 | Except for the limited purpose of indicating to the public that the
310 | Work is licensed under the CCPL, Creative Commons does not authorize
311 | the use by either party of the trademark "Creative Commons" or any
312 | related trademark or logo of Creative Commons without the prior
313 | written consent of Creative Commons. Any permitted use will be in
314 | compliance with Creative Commons' then-current trademark usage
315 | guidelines, as may be published on its website or otherwise made
316 | available upon request from time to time. For the avoidance of doubt,
317 | this trademark restriction does not form part of this License.
318 |
319 | Creative Commons may be contacted at http://creativecommons.org/.
--------------------------------------------------------------------------------
/docs/assets/css/docs.min.css:
--------------------------------------------------------------------------------
1 | /*!
2 | * Bootstrap Docs (http://getbootstrap.com)
3 | * Copyright 2011-2014 Twitter, Inc.
4 | * Licensed under the Creative Commons Attribution 3.0 Unported License. For
5 | * details, see http://creativecommons.org/licenses/by/3.0/.
6 | */body{position:relative}.table code{font-size:13px;font-weight:400}.btn-outline{color:#563d7c;background-color:transparent;border-color:#563d7c}.btn-outline:hover,.btn-outline:focus,.btn-outline:active{color:#fff;background-color:#563d7c;border-color:#563d7c}.btn-outline-inverse{color:#fff;background-color:transparent;border-color:#cdbfe3}.btn-outline-inverse:hover,.btn-outline-inverse:focus,.btn-outline-inverse:active{color:#563d7c;text-shadow:none;background-color:#fff;border-color:#fff}.bs-docs-booticon{display:block;font-weight:500;color:#fff;text-align:center;cursor:default;background-color:#563d7c;border-radius:15%}.bs-docs-booticon-sm{width:30px;height:30px;font-size:20px;line-height:28px}.bs-docs-booticon-lg{width:144px;height:144px;font-size:108px;line-height:140px}.bs-docs-booticon-inverse{color:#563d7c;background-color:#fff}.bs-docs-booticon-outline{background-color:transparent;border:1px solid #cdbfe3}.bs-docs-nav{margin-bottom:0;background-color:#fff;border-bottom:0}.bs-home-nav .bs-nav-b{display:none}.bs-docs-nav .navbar-brand,.bs-docs-nav .navbar-nav>li>a{font-weight:500;color:#563d7c}.bs-docs-nav .navbar-nav>li>a:hover,.bs-docs-nav .navbar-nav>.active>a,.bs-docs-nav .navbar-nav>.active>a:hover{color:#463265;background-color:#f9f9f9}.bs-docs-nav .navbar-toggle .icon-bar{background-color:#563d7c}.bs-docs-nav .navbar-header .navbar-toggle{border-color:#fff}.bs-docs-nav .navbar-header .navbar-toggle:hover,.bs-docs-nav .navbar-header .navbar-toggle:focus{background-color:#f9f9f9;border-color:#f9f9f9}.bs-docs-footer{padding-top:40px;padding-bottom:40px;margin-top:100px;color:#777;text-align:center;border-top:1px solid #e5e5e5}.bs-docs-footer-links{padding-left:0;margin-top:20px;color:#999}.bs-docs-footer-links li{display:inline;padding:0 2px}.bs-docs-footer-links li:first-child{padding-left:0}@media (min-width:768px){.bs-docs-footer p{margin-bottom:0}}.bs-docs-social{margin-bottom:20px;text-align:center}.bs-docs-social-buttons{display:inline-block;padding-left:0;margin-bottom:0;list-style:none}.bs-docs-social-buttons li{display:inline-block;padding:5px 8px;line-height:1}.bs-docs-social-buttons .twitter-follow-button{width:225px!important}.bs-docs-social-buttons .twitter-share-button{width:98px!important}.github-btn{overflow:hidden;border:0}.bs-docs-masthead,.bs-docs-header{position:relative;padding:30px 15px;color:#cdbfe3;text-align:center;text-shadow:0 1px 0 rgba(0,0,0,.1);background-color:#6f5499;background-image:-webkit-gradient(linear,left top,left bottom,from(#563d7c),to(#6f5499));background-image:-webkit-linear-gradient(top,#563d7c 0,#6f5499 100%);background-image:-o-linear-gradient(top,#563d7c 0,#6f5499 100%);background-image:linear-gradient(to bottom,#563d7c 0,#6f5499 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#563d7c', endColorstr='#6F5499', GradientType=0);background-repeat:repeat-x}.bs-docs-masthead .bs-docs-booticon{margin:0 auto 30px}.bs-docs-masthead h1{font-weight:300;line-height:1;color:#fff}.bs-docs-masthead .lead{margin:0 auto 30px;font-size:20px;color:#fff}.bs-docs-masthead .version{margin-top:-15px;margin-bottom:30px;color:#9783b9}.bs-docs-masthead .btn{width:100%;padding:15px 30px;font-size:20px}@media (min-width:480px){.bs-docs-masthead .btn{width:auto}}@media (min-width:768px){.bs-docs-masthead{padding:80px 0}.bs-docs-masthead h1{font-size:60px}.bs-docs-masthead .lead{font-size:24px}}@media (min-width:992px){.bs-docs-masthead .lead{width:80%;font-size:30px}}.bs-docs-header{margin-bottom:40px;font-size:20px}.bs-docs-header h1{margin-top:0;color:#fff}.bs-docs-header p{margin-bottom:0;font-weight:300;line-height:1.4}.bs-docs-header .container{position:relative}@media (min-width:768px){.bs-docs-header{padding-top:60px;padding-bottom:60px;font-size:24px;text-align:left}.bs-docs-header h1{font-size:60px;line-height:1}}@media (min-width:992px){.bs-docs-header h1,.bs-docs-header p{margin-right:380px}}.carbonad{width:auto!important;height:auto!important;padding:20px!important;margin:30px -30px -31px!important;overflow:hidden;font-size:13px!important;line-height:16px!important;text-align:left;background:transparent!important;border:solid #866ab3!important;border-width:1px 0!important}.carbonad-img{margin:0!important}.carbonad-text,.carbonad-tag{display:block!important;float:none!important;width:auto!important;height:auto!important;margin-left:145px!important;font-family:"Helvetica Neue",Helvetica,Arial,sans-serif!important}.carbonad-text{padding-top:0!important}.carbonad-tag{color:inherit!important;text-align:left!important}.carbonad-text a,.carbonad-tag a{color:#fff!important}.carbonad #azcarbon>img{display:none}@media (min-width:480px){.carbonad{width:330px!important;margin:20px auto!important;border-width:1px!important;border-radius:4px}.bs-docs-masthead .carbonad{margin:50px auto 0!important}}@media (min-width:768px){.carbonad{margin-right:0!important;margin-left:0!important}}@media (min-width:992px){.carbonad{position:absolute;top:0;right:15px;width:330px!important;padding:15px!important;margin:0!important}.bs-docs-masthead .carbonad{position:static}}.bs-docs-featurette{padding-top:40px;padding-bottom:40px;font-size:16px;line-height:1.5;color:#555;text-align:center;background-color:#fff;border-bottom:1px solid #e5e5e5}.bs-docs-featurette+.bs-docs-footer{margin-top:0;border-top:0}.bs-docs-featurette-title{margin-bottom:5px;font-size:30px;font-weight:400;color:#333}.half-rule{width:100px;margin:40px auto}.bs-docs-featurette h3{margin-bottom:5px;font-weight:400;color:#333}.bs-docs-featurette-img{display:block;margin-bottom:20px;color:#333}.bs-docs-featurette-img:hover{color:#428bca;text-decoration:none}.bs-docs-featurette-img img{display:block;margin-bottom:15px}@media (min-width:480px){.bs-docs-featurette .img-responsive{margin-top:30px}}@media (min-width:768px){.bs-docs-featurette{padding-top:100px;padding-bottom:100px}.bs-docs-featurette-title{font-size:40px}.bs-docs-featurette .lead{max-width:80%;margin-right:auto;margin-left:auto}.bs-docs-featurette .img-responsive{margin-top:0}}.bs-docs-featured-sites{margin-right:-1px;margin-left:-1px}.bs-docs-featured-sites .col-xs-6{padding:1px}.bs-docs-featured-sites .img-responsive{margin-top:0}@media (min-width:768px){.bs-docs-featured-sites .col-sm-3:first-child img{border-top-left-radius:4px;border-bottom-left-radius:4px}.bs-docs-featured-sites .col-sm-3:last-child img{border-top-right-radius:4px;border-bottom-right-radius:4px}}.bs-examples .thumbnail{margin-bottom:10px}.bs-examples h4{margin-bottom:5px}.bs-examples p{margin-bottom:20px}@media (max-width:480px){.bs-examples{margin-right:-10px;margin-left:-10px}.bs-examples>[class^=col-]{padding-right:10px;padding-left:10px}}.bs-docs-sidebar.affix{position:static}@media (min-width:768px){.bs-docs-sidebar{padding-left:20px}}.bs-docs-sidenav{margin-top:20px;margin-bottom:20px}.bs-docs-sidebar .nav>li>a{display:block;padding:4px 20px;font-size:13px;font-weight:500;color:#999}.bs-docs-sidebar .nav>li>a:hover,.bs-docs-sidebar .nav>li>a:focus{padding-left:19px;color:#563d7c;text-decoration:none;background-color:transparent;border-left:1px solid #563d7c}.bs-docs-sidebar .nav>.active>a,.bs-docs-sidebar .nav>.active:hover>a,.bs-docs-sidebar .nav>.active:focus>a{padding-left:18px;font-weight:700;color:#563d7c;background-color:transparent;border-left:2px solid #563d7c}.bs-docs-sidebar .nav .nav{display:none;padding-bottom:10px}.bs-docs-sidebar .nav .nav>li>a{padding-top:1px;padding-bottom:1px;padding-left:30px;font-size:12px;font-weight:400}.bs-docs-sidebar .nav .nav>li>a:hover,.bs-docs-sidebar .nav .nav>li>a:focus{padding-left:29px}.bs-docs-sidebar .nav .nav>.active>a,.bs-docs-sidebar .nav .nav>.active:hover>a,.bs-docs-sidebar .nav .nav>.active:focus>a{padding-left:28px;font-weight:500}.back-to-top,.bs-docs-theme-toggle{display:none;padding:4px 10px;margin-top:10px;margin-left:10px;font-size:12px;font-weight:500;color:#999}.back-to-top:hover,.bs-docs-theme-toggle:hover{color:#563d7c;text-decoration:none}.bs-docs-theme-toggle{margin-top:0}@media (min-width:768px){.back-to-top,.bs-docs-theme-toggle{display:block}}@media (min-width:992px){.bs-docs-sidebar .nav>.active>ul{display:block}.bs-docs-sidebar.affix,.bs-docs-sidebar.affix-bottom{width:213px}.bs-docs-sidebar.affix{position:fixed;top:20px}.bs-docs-sidebar.affix-bottom{position:absolute}.bs-docs-sidebar.affix-bottom .bs-docs-sidenav,.bs-docs-sidebar.affix .bs-docs-sidenav{margin-top:0;margin-bottom:0}}@media (min-width:1200px){.bs-docs-sidebar.affix-bottom,.bs-docs-sidebar.affix{width:263px}}.bs-docs-section{margin-bottom:60px}.bs-docs-section:last-child{margin-bottom:0}h1[id]{padding-top:20px;margin-top:0}.bs-callout{padding:20px;margin:20px 0;border:1px solid #eee;border-left-width:5px;border-radius:3px}.bs-callout h4{margin-top:0;margin-bottom:5px}.bs-callout p:last-child{margin-bottom:0}.bs-callout code{border-radius:3px}.bs-callout+.bs-callout{margin-top:-5px}.bs-callout-danger{border-left-color:#d9534f}.bs-callout-danger h4{color:#d9534f}.bs-callout-warning{border-left-color:#f0ad4e}.bs-callout-warning h4{color:#f0ad4e}.bs-callout-info{border-left-color:#5bc0de}.bs-callout-info h4{color:#5bc0de}.color-swatches{margin:0 -5px;overflow:hidden}.color-swatch{float:left;width:60px;height:60px;margin:0 5px;border-radius:3px}@media (min-width:768px){.color-swatch{width:100px;height:100px}}.color-swatches .gray-darker{background-color:#222}.color-swatches .gray-dark{background-color:#333}.color-swatches .gray{background-color:#555}.color-swatches .gray-light{background-color:#999}.color-swatches .gray-lighter{background-color:#eee}.color-swatches .brand-primary{background-color:#428bca}.color-swatches .brand-success{background-color:#5cb85c}.color-swatches .brand-warning{background-color:#f0ad4e}.color-swatches .brand-danger{background-color:#d9534f}.color-swatches .brand-info{background-color:#5bc0de}.color-swatches .bs-purple{background-color:#563d7c}.color-swatches .bs-purple-light{background-color:#c7bfd3}.color-swatches .bs-purple-lighter{background-color:#e5e1ea}.color-swatches .bs-gray{background-color:#f9f9f9}.bs-team .team-member{line-height:32px;color:#555}.bs-team .team-member:hover{color:#333;text-decoration:none}.bs-team .github-btn{float:right;width:180px;height:20px;margin-top:6px}.bs-team img{float:left;width:32px;margin-right:10px;border-radius:4px}.bs-docs-browser-bugs td p{margin-bottom:0}.bs-docs-browser-bugs th:first-child{width:18%}.show-grid{margin-bottom:15px}.show-grid [class^=col-]{padding-top:10px;padding-bottom:10px;background-color:#eee;background-color:rgba(86,61,124,.15);border:1px solid #ddd;border:1px solid rgba(86,61,124,.2)}.bs-example{position:relative;padding:45px 15px 15px;margin:0 -15px 15px;border-color:#e5e5e5 #eee #eee;border-style:solid;border-width:1px 0;-webkit-box-shadow:inset 0 3px 6px rgba(0,0,0,.05);box-shadow:inset 0 3px 6px rgba(0,0,0,.05)}.bs-example:after{position:absolute;top:15px;left:15px;font-size:12px;font-weight:700;color:#959595;text-transform:uppercase;letter-spacing:1px;content:"Example"}.bs-example+.highlight,.bs-example+.zero-clipboard+.highlight{margin:-15px -15px 15px;border-width:0 0 1px;border-radius:0}@media (min-width:768px){.bs-example{margin-right:0;margin-left:0;background-color:#fff;border-color:#ddd;border-width:1px;border-radius:4px 4px 0 0;-webkit-box-shadow:none;box-shadow:none}.bs-example+.highlight,.bs-example+.zero-clipboard+.highlight{margin-top:-16px;margin-right:0;margin-left:0;border-width:1px;border-bottom-right-radius:4px;border-bottom-left-radius:4px}.bs-example-standalone{border-radius:4px}}.bs-example .container{width:auto}.bs-example>p:last-child,.bs-example>ul:last-child,.bs-example>ol:last-child,.bs-example>blockquote:last-child,.bs-example>.form-control:last-child,.bs-example>.table:last-child,.bs-example>.navbar:last-child,.bs-example>.jumbotron:last-child,.bs-example>.alert:last-child,.bs-example>.panel:last-child,.bs-example>.list-group:last-child,.bs-example>.well:last-child,.bs-example>.progress:last-child,.bs-example>.table-responsive:last-child>.table{margin-bottom:0}.bs-example>p>.close{float:none}.bs-example-type .table .type-info{color:#999;vertical-align:middle}.bs-example-type .table td{padding:15px 0;border-color:#eee}.bs-example-type .table tr:first-child td{border-top:0}.bs-example-type h1,.bs-example-type h2,.bs-example-type h3,.bs-example-type h4,.bs-example-type h5,.bs-example-type h6{margin:0}.bs-example-bg-classes p{padding:15px}.bs-example>.img-circle,.bs-example>.img-rounded,.bs-example>.img-thumbnail{margin:5px}.bs-example>.table-responsive>.table{background-color:#fff}.bs-example>.btn,.bs-example>.btn-group{margin-top:5px;margin-bottom:5px}.bs-example>.btn-toolbar+.btn-toolbar{margin-top:10px}.bs-example-control-sizing select,.bs-example-control-sizing input[type=text]+input[type=text]{margin-top:10px}.bs-example-form .input-group{margin-bottom:10px}.bs-example>textarea.form-control{resize:vertical}.bs-example>.list-group{max-width:400px}.bs-example .navbar:last-child{margin-bottom:0}.bs-navbar-top-example,.bs-navbar-bottom-example{z-index:1;padding:0;overflow:hidden}.bs-navbar-top-example .navbar-header,.bs-navbar-bottom-example .navbar-header{margin-left:0}.bs-navbar-top-example .navbar-fixed-top,.bs-navbar-bottom-example .navbar-fixed-bottom{position:relative;margin-right:0;margin-left:0}.bs-navbar-top-example{padding-bottom:45px}.bs-navbar-top-example:after{top:auto;bottom:15px}.bs-navbar-top-example .navbar-fixed-top{top:-1px}.bs-navbar-bottom-example{padding-top:45px}.bs-navbar-bottom-example .navbar-fixed-bottom{bottom:-1px}.bs-navbar-bottom-example .navbar{margin-bottom:0}@media (min-width:768px){.bs-navbar-top-example .navbar-fixed-top,.bs-navbar-bottom-example .navbar-fixed-bottom{position:absolute}}.bs-example .pagination{margin-top:10px;margin-bottom:10px}.bs-example>.pager{margin-top:0}.bs-example-modal{background-color:#f5f5f5}.bs-example-modal .modal{position:relative;top:auto;right:auto;bottom:auto;left:auto;z-index:1;display:block}.bs-example-modal .modal-dialog{left:auto;margin-right:auto;margin-left:auto}.bs-example>.dropdown>.dropdown-toggle{float:left}.bs-example>.dropdown>.dropdown-menu{position:static;display:block;margin-bottom:5px;clear:left}.bs-example-tabs .nav-tabs{margin-bottom:15px}.bs-example-tooltips{text-align:center}.bs-example-tooltips>.btn{margin-top:5px;margin-bottom:5px}.bs-example-tooltip .tooltip{position:relative;display:inline-block;margin:10px 20px;opacity:1}.bs-example-popover{padding-bottom:24px;background-color:#f9f9f9}.bs-example-popover .popover{position:relative;display:block;float:left;width:260px;margin:20px}.scrollspy-example{position:relative;height:200px;margin-top:10px;overflow:auto}.highlight{padding:9px 14px;margin-bottom:14px;background-color:#f7f7f9;border:1px solid #e1e1e8;border-radius:4px}.highlight pre{padding:0;margin-top:0;margin-bottom:0;word-break:normal;white-space:nowrap;background-color:transparent;border:0}.highlight pre code{font-size:inherit;color:#333}.highlight pre code:first-child{display:inline-block;padding-right:45px}.table-responsive .highlight pre{white-space:normal}.bs-table th small,.responsive-utilities th small{display:block;font-weight:400;color:#999}.responsive-utilities tbody th{font-weight:400}.responsive-utilities td{text-align:center}.responsive-utilities td.is-visible{color:#468847;background-color:#dff0d8!important}.responsive-utilities td.is-hidden{color:#ccc;background-color:#f9f9f9!important}.responsive-utilities-test{margin-top:5px}.responsive-utilities-test .col-xs-6{margin-bottom:10px}.responsive-utilities-test span{display:block;padding:15px 10px;font-size:14px;font-weight:700;line-height:1.1;text-align:center;border-radius:4px}.visible-on .col-xs-6 .hidden-xs,.visible-on .col-xs-6 .hidden-sm,.visible-on .col-xs-6 .hidden-md,.visible-on .col-xs-6 .hidden-lg,.hidden-on .col-xs-6 .hidden-xs,.hidden-on .col-xs-6 .hidden-sm,.hidden-on .col-xs-6 .hidden-md,.hidden-on .col-xs-6 .hidden-lg{color:#999;border:1px solid #ddd}.visible-on .col-xs-6 .visible-xs-block,.visible-on .col-xs-6 .visible-sm-block,.visible-on .col-xs-6 .visible-md-block,.visible-on .col-xs-6 .visible-lg-block,.hidden-on .col-xs-6 .visible-xs-block,.hidden-on .col-xs-6 .visible-sm-block,.hidden-on .col-xs-6 .visible-md-block,.hidden-on .col-xs-6 .visible-lg-block{color:#468847;background-color:#dff0d8;border:1px solid #d6e9c6}.bs-glyphicons{margin:0 -10px 20px;overflow:hidden}.bs-glyphicons-list{padding-left:0;list-style:none}.bs-glyphicons li{float:left;width:25%;height:115px;padding:10px;font-size:10px;line-height:1.4;text-align:center;background-color:#f9f9f9;border:1px solid #fff}.bs-glyphicons .glyphicon{margin-top:5px;margin-bottom:10px;font-size:24px}.bs-glyphicons .glyphicon-class{display:block;text-align:center;word-wrap:break-word}.bs-glyphicons li:hover{color:#fff;background-color:#563d7c}@media (min-width:768px){.bs-glyphicons{margin-right:0;margin-left:0}.bs-glyphicons li{width:12.5%;font-size:12px}}.bs-customizer .toggle{float:right;margin-top:25px}.bs-customizer label{margin-top:10px;font-weight:500;color:#555}.bs-customizer h2{padding-top:30px;margin-top:0;margin-bottom:5px}.bs-customizer h3{margin-bottom:0}.bs-customizer h4{margin-top:15px;margin-bottom:0}.bs-customizer .bs-callout h4{margin-top:0;margin-bottom:5px}.bs-customizer input[type=text]{font-family:Menlo,Monaco,Consolas,"Courier New",monospace;background-color:#fafafa}.bs-customizer .help-block{margin-bottom:5px;font-size:12px}#less-section label{font-weight:400}.bs-customize-download .btn-outline{padding:20px}.bs-customizer-alert{position:fixed;top:0;right:0;left:0;z-index:1030;padding:15px 0;color:#fff;background-color:#d9534f;border-bottom:1px solid #b94441;-webkit-box-shadow:inset 0 1px 0 rgba(255,255,255,.25);box-shadow:inset 0 1px 0 rgba(255,255,255,.25)}.bs-customizer-alert .close{margin-top:-4px;font-size:24px}.bs-customizer-alert p{margin-bottom:0}.bs-customizer-alert .glyphicon{margin-right:5px}.bs-customizer-alert pre{margin:10px 0 0;color:#fff;background-color:#a83c3a;border-color:#973634;-webkit-box-shadow:inset 0 2px 4px rgba(0,0,0,.05),0 1px 0 rgba(255,255,255,.1);box-shadow:inset 0 2px 4px rgba(0,0,0,.05),0 1px 0 rgba(255,255,255,.1)}.bs-dropzone{position:relative;padding:20px;margin-bottom:20px;color:#777;text-align:center;border:2px dashed #eee;border-radius:4px}.bs-dropzone h2{margin-top:0;margin-bottom:5px}.bs-dropzone hr{width:100px}.bs-dropzone .lead{margin-bottom:10px;font-weight:400;color:#333}#import-manual-trigger{cursor:pointer}.bs-dropzone p:last-child{margin-bottom:0}.bs-brand-logos{display:table;width:100%;margin-bottom:15px;overflow:hidden;color:#563d7c;background-color:#f9f9f9;border-radius:4px}.bs-brand-item{padding:60px 0;text-align:center}.bs-brand-item+.bs-brand-item{border-top:1px solid #fff}.bs-brand-logos .inverse{color:#fff;background-color:#563d7c}.bs-brand-item .svg{width:144px;height:144px}.bs-brand-item h1,.bs-brand-item h3{margin-top:0;margin-bottom:0}.bs-brand-item .bs-docs-booticon{margin-right:auto;margin-left:auto}.bs-brand-item .glyphicon{width:30px;height:30px;margin:10px auto -10px;line-height:30px;color:#fff;border-radius:50%}.bs-brand-item .glyphicon-ok{background-color:#5cb85c}.bs-brand-item .glyphicon-remove{background-color:#d9534f}@media (min-width:768px){.bs-brand-item{display:table-cell;width:1%}.bs-brand-item+.bs-brand-item{border-top:0;border-left:1px solid #fff}.bs-brand-item h1{font-size:60px}}.zero-clipboard{position:relative;display:none}.btn-clipboard{position:absolute;top:0;right:0;z-index:10;display:block;padding:5px 8px;font-size:12px;color:#777;cursor:pointer;background-color:#fff;border:1px solid #e1e1e8;border-radius:0 4px 0 4px}.btn-clipboard-hover{color:#fff;background-color:#563d7c;border-color:#563d7c}@media (min-width:768px){.zero-clipboard{display:block}.bs-example+.zero-clipboard .btn-clipboard{top:-16px;border-top-right-radius:0}}#focusedInput{border-color:#ccc;border-color:rgba(82,168,236,.8);outline:0;outline:thin dotted \9;-webkit-box-shadow:0 0 8px rgba(82,168,236,.6);box-shadow:0 0 8px rgba(82,168,236,.6)}.hll{background-color:#ffc}.c{color:#999}.err{color:#A00;background-color:#FAA}.k{color:#069}.o{color:#555}.cm{color:#999}.cp{color:#099}.c1{color:#999}.cs{color:#999}.gd{background-color:#FCC;border:1px solid #C00}.ge{font-style:italic}.gr{color:red}.gh{color:#030}.gi{background-color:#CFC;border:1px solid #0C0}.go{color:#AAA}.gp{color:#009}.gu{color:#030}.gt{color:#9C6}.kc{color:#069}.kd{color:#069}.kn{color:#069}.kp{color:#069}.kr{color:#069}.kt{color:#078}.m{color:#F60}.s{color:#d44950}.na{color:#4f9fcf}.nb{color:#366}.nc{color:#0A8}.no{color:#360}.nd{color:#99F}.ni{color:#999}.ne{color:#C00}.nf{color:#C0F}.nl{color:#99F}.nn{color:#0CF}.nt{color:#2f6f9f}.nv{color:#033}.ow{color:#000}.w{color:#bbb}.mf{color:#F60}.mh{color:#F60}.mi{color:#F60}.mo{color:#F60}.sb{color:#C30}.sc{color:#C30}.sd{color:#C30;font-style:italic}.s2{color:#C30}.se{color:#C30}.sh{color:#C30}.si{color:#A00}.sx{color:#C30}.sr{color:#3AA}.s1{color:#C30}.ss{color:#FC3}.bp{color:#366}.vc{color:#033}.vg{color:#033}.vi{color:#033}.il{color:#F60}.css .o,.css .o+.nt,.css .nt+.nt{color:#999}
7 |
--------------------------------------------------------------------------------