Topo2: Reset node position and unpin
Refactored NodeModel Added class to the surrounding rect for selected class Renamed Panels to avoid conflict with classic topo Topo2: Details Panel for single device selection Topo2: Added Equalize Masters keyboard shortcut Topo2: Toggle Link Port highlighting Topo2: Node Labels was returning empty string if friendly name was null Topo2: Reset map zoom and panning Change-Id: I0a949b2f8205e1abcfcac5aaec65c18d76e77cff
Showing
20 changed files
with
804 additions
and
194 deletions
... | @@ -66,7 +66,6 @@ | ... | @@ -66,7 +66,6 @@ |
66 | } | 66 | } |
67 | 67 | ||
68 | function updatePrefs(data) { | 68 | function updatePrefs(data) { |
69 | - $log.info('User properties updated'); | ||
70 | cache = data; | 69 | cache = data; |
71 | listeners.forEach(function (lsnr) { lsnr(); }); | 70 | listeners.forEach(function (lsnr) { lsnr(); }); |
72 | } | 71 | } | ... | ... |
... | @@ -3,7 +3,8 @@ module.exports = { | ... | @@ -3,7 +3,8 @@ module.exports = { |
3 | "installedESLint": true, | 3 | "installedESLint": true, |
4 | "globals": { | 4 | "globals": { |
5 | "angular": true, | 5 | "angular": true, |
6 | - "d3": true | 6 | + "d3": true, |
7 | + "_": true | ||
7 | }, | 8 | }, |
8 | "rules": { | 9 | "rules": { |
9 | "brace-style": 0, | 10 | "brace-style": 0, | ... | ... |
... | @@ -99,3 +99,29 @@ | ... | @@ -99,3 +99,29 @@ |
99 | cursor: pointer; | 99 | cursor: pointer; |
100 | fill-rule: evenodd; | 100 | fill-rule: evenodd; |
101 | } | 101 | } |
102 | + | ||
103 | +/* --- Topo Summary Panel --- */ | ||
104 | + | ||
105 | +#topo2-p-summary { | ||
106 | + padding: 16px; | ||
107 | +} | ||
108 | + | ||
109 | + | ||
110 | +/* --- Topo Detail Panel --- */ | ||
111 | + | ||
112 | +#topo2-p-detail { | ||
113 | + padding: 16px; | ||
114 | + top: 370px; | ||
115 | +} | ||
116 | +html[data-platform='iPad'] #topo2-p-detail { | ||
117 | + top: 386px; | ||
118 | +} | ||
119 | + | ||
120 | +#topo2-p-detail .actionBtns .actionBtn { | ||
121 | + display: inline-block; | ||
122 | +} | ||
123 | +#topo2-p-detail .actionBtns .actionBtn svg { | ||
124 | + width: 28px; | ||
125 | + height: 28px; | ||
126 | +} | ||
127 | + | ... | ... |
... | @@ -24,7 +24,7 @@ | ... | @@ -24,7 +24,7 @@ |
24 | 'use strict'; | 24 | 'use strict'; |
25 | 25 | ||
26 | // references to injected services | 26 | // references to injected services |
27 | - var $scope, $log, fs, mast, ks, zs, | 27 | + var $scope, $log, fs, mast, ks, |
28 | gs, sus, ps, t2es, t2fs, t2is, t2bcs, t2kcs, t2ms, t2mcs, t2zs; | 28 | gs, sus, ps, t2es, t2fs, t2is, t2bcs, t2kcs, t2ms, t2mcs, t2zs; |
29 | 29 | ||
30 | // DOM elements | 30 | // DOM elements |
... | @@ -81,19 +81,20 @@ | ... | @@ -81,19 +81,20 @@ |
81 | angular.module('ovTopo2', ['onosUtil', 'onosSvg', 'onosRemote']) | 81 | angular.module('ovTopo2', ['onosUtil', 'onosSvg', 'onosRemote']) |
82 | .controller('OvTopo2Ctrl', | 82 | .controller('OvTopo2Ctrl', |
83 | ['$scope', '$log', '$location', | 83 | ['$scope', '$log', '$location', |
84 | - 'FnService', 'MastService', 'KeyService', 'ZoomService', | 84 | + 'FnService', 'MastService', 'KeyService', |
85 | 'GlyphService', 'MapService', 'SvgUtilService', 'FlashService', | 85 | 'GlyphService', 'MapService', 'SvgUtilService', 'FlashService', |
86 | 'WebSocketService', 'PrefsService', 'ThemeService', | 86 | 'WebSocketService', 'PrefsService', 'ThemeService', |
87 | 'Topo2EventService', 'Topo2ForceService', 'Topo2InstanceService', | 87 | 'Topo2EventService', 'Topo2ForceService', 'Topo2InstanceService', |
88 | 'Topo2BreadcrumbService', 'Topo2KeyCommandService', 'Topo2MapService', | 88 | 'Topo2BreadcrumbService', 'Topo2KeyCommandService', 'Topo2MapService', |
89 | - 'Topo2MapConfigService', 'Topo2SummaryPanelService', 'Topo2ZoomService', | 89 | + 'Topo2MapConfigService', 'Topo2ZoomService', |
90 | + 'Topo2SummaryPanelService', 'Topo2DeviceDetailsPanel', | ||
90 | 91 | ||
91 | function (_$scope_, _$log_, _$loc_, | 92 | function (_$scope_, _$log_, _$loc_, |
92 | - _fs_, _mast_, _ks_, _zs_, | 93 | + _fs_, _mast_, _ks_, |
93 | _gs_, _ms_, _sus_, _flash_, | 94 | _gs_, _ms_, _sus_, _flash_, |
94 | _wss_, _ps_, _th_, | 95 | _wss_, _ps_, _th_, |
95 | _t2es_, _t2fs_, _t2is_, _t2bcs_, _t2kcs_, _t2ms_, _t2mcs_, | 96 | _t2es_, _t2fs_, _t2is_, _t2bcs_, _t2kcs_, _t2ms_, _t2mcs_, |
96 | - summaryPanel, _t2zs_ | 97 | + _t2zs_, summaryPanel, detailsPanel |
97 | ) { | 98 | ) { |
98 | 99 | ||
99 | var params = _$loc_.search(), | 100 | var params = _$loc_.search(), |
... | @@ -115,7 +116,6 @@ | ... | @@ -115,7 +116,6 @@ |
115 | fs = _fs_; | 116 | fs = _fs_; |
116 | mast = _mast_; | 117 | mast = _mast_; |
117 | ks = _ks_; | 118 | ks = _ks_; |
118 | - zs = _zs_; | ||
119 | 119 | ||
120 | gs = _gs_; | 120 | gs = _gs_; |
121 | sus = _sus_; | 121 | sus = _sus_; |
... | @@ -156,6 +156,8 @@ | ... | @@ -156,6 +156,8 @@ |
156 | ks.unbindKeys(); | 156 | ks.unbindKeys(); |
157 | t2fs.destroy(); | 157 | t2fs.destroy(); |
158 | t2is.destroy(); | 158 | t2is.destroy(); |
159 | + summaryPanel.destroy(); | ||
160 | + detailsPanel.destroy(); | ||
159 | }); | 161 | }); |
160 | 162 | ||
161 | // svg layer and initialization of components | 163 | // svg layer and initialization of components |
... | @@ -176,7 +178,7 @@ | ... | @@ -176,7 +178,7 @@ |
176 | t2es.bindHandlers(); | 178 | t2es.bindHandlers(); |
177 | 179 | ||
178 | // Add the map SVG Group | 180 | // Add the map SVG Group |
179 | - t2ms.init(zoomLayer).then( | 181 | + t2ms.init(zoomLayer, zoomer).then( |
180 | function (proj) { | 182 | function (proj) { |
181 | var z = ps.getPrefs('topo_zoom', { tx: 0, ty: 0, sc: 1 }); | 183 | var z = ps.getPrefs('topo_zoom', { tx: 0, ty: 0, sc: 1 }); |
182 | zoomer.panZoom([z.tx, z.ty], z.sc); | 184 | zoomer.panZoom([z.tx, z.ty], z.sc); |
... | @@ -219,6 +221,7 @@ | ... | @@ -219,6 +221,7 @@ |
219 | // $log.debug('registered overlays...', tov.list()); | 221 | // $log.debug('registered overlays...', tov.list()); |
220 | 222 | ||
221 | summaryPanel.init(); | 223 | summaryPanel.init(); |
224 | + detailsPanel.init(); | ||
222 | 225 | ||
223 | $log.log('OvTopo2Ctrl has been created'); | 226 | $log.log('OvTopo2Ctrl has been created'); |
224 | }]); | 227 | }]); | ... | ... |
... | @@ -34,10 +34,10 @@ | ... | @@ -34,10 +34,10 @@ |
34 | var DeviceCollection = Collection.extend({ | 34 | var DeviceCollection = Collection.extend({ |
35 | model: Model, | 35 | model: Model, |
36 | comparator: function (a, b) { | 36 | comparator: function (a, b) { |
37 | - var order = region.get('layerOrder'), | 37 | + // var order = region.get('layerOrder'), |
38 | - aLayer = a.get('layer'), | 38 | + // aLayer = a.get('id'), |
39 | - bLayer = b.get('layer'); | 39 | + // bLayer = b.get('layer'); |
40 | - return order.indexOf(aLayer - order.indexOf(bLayer)); | 40 | + // return order.indexOf(aLayer - order.indexOf(bLayer)); |
41 | } | 41 | } |
42 | }); | 42 | }); |
43 | 43 | ||
... | @@ -54,11 +54,10 @@ | ... | @@ -54,11 +54,10 @@ |
54 | return deviceCollection; | 54 | return deviceCollection; |
55 | } | 55 | } |
56 | 56 | ||
57 | - | ||
58 | angular.module('ovTopo2') | 57 | angular.module('ovTopo2') |
59 | .factory('Topo2DeviceService', | 58 | .factory('Topo2DeviceService', |
60 | - ['Topo2Collection', 'Topo2NodeModel', | 59 | + ['Topo2Collection', 'Topo2NodeModel', 'Topo2DeviceDetailsPanel', |
61 | - function (_c_, _nm_) { | 60 | + function (_c_, _nm_, detailsPanel) { |
62 | 61 | ||
63 | Collection = _c_; | 62 | Collection = _c_; |
64 | 63 | ||
... | @@ -67,11 +66,27 @@ | ... | @@ -67,11 +66,27 @@ |
67 | this.super = this.constructor.__super__; | 66 | this.super = this.constructor.__super__; |
68 | this.super.initialize.apply(this, arguments); | 67 | this.super.initialize.apply(this, arguments); |
69 | }, | 68 | }, |
69 | + events: { | ||
70 | + 'click': 'onClick' | ||
71 | + }, | ||
70 | nodeType: 'device', | 72 | nodeType: 'device', |
71 | icon: function () { | 73 | icon: function () { |
72 | var type = this.get('type'); | 74 | var type = this.get('type'); |
73 | return remappedDeviceTypes[type] || type || 'unknown'; | 75 | return remappedDeviceTypes[type] || type || 'unknown'; |
74 | }, | 76 | }, |
77 | + onClick: function () { | ||
78 | + | ||
79 | + if (this.get('selected')) { | ||
80 | + this.set('selected', false); | ||
81 | + detailsPanel.hide(); | ||
82 | + } else { | ||
83 | + this.set('selected', true); | ||
84 | + detailsPanel.updateDetails(this.get('id'), this.get('nodeType')); | ||
85 | + detailsPanel.show(); | ||
86 | + } | ||
87 | + | ||
88 | + this.el.attr('class', this.svgClassName()); | ||
89 | + }, | ||
75 | onExit: function () { | 90 | onExit: function () { |
76 | var node = this.el; | 91 | var node = this.el; |
77 | node.select('use') | 92 | node.select('use') | ... | ... |
1 | +/* | ||
2 | + * Copyright 2016-present Open Networking Laboratory | ||
3 | + * | ||
4 | + * Licensed under the Apache License, Version 2.0 (the "License"); | ||
5 | + * you may not use this file except in compliance with the License. | ||
6 | + * You may obtain a copy of the License at | ||
7 | + * | ||
8 | + * http://www.apache.org/licenses/LICENSE-2.0 | ||
9 | + * | ||
10 | + * Unless required by applicable law or agreed to in writing, software | ||
11 | + * distributed under the License is distributed on an "AS IS" BASIS, | ||
12 | + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
13 | + * See the License for the specific language governing permissions and | ||
14 | + * limitations under the License. | ||
15 | + */ | ||
16 | + | ||
17 | +/* | ||
18 | + ONOS GUI -- Topology View Module. | ||
19 | + Module that displays the details panel for selected nodes | ||
20 | + */ | ||
21 | + | ||
22 | +(function () { | ||
23 | + 'use strict'; | ||
24 | + | ||
25 | + // Injected Services | ||
26 | + var Panel, gs, wss, flash, bs, fs, ns; | ||
27 | + | ||
28 | + // Internal State | ||
29 | + var detailsPanel; | ||
30 | + | ||
31 | + // configuration | ||
32 | + var id = 'topo2-p-detail', | ||
33 | + className = 'topo-p', | ||
34 | + panelOpts = { | ||
35 | + width: 260 // summary and detail panel width | ||
36 | + }, | ||
37 | + handlerMap = { | ||
38 | + 'showDetails': showDetails | ||
39 | + }; | ||
40 | + | ||
41 | + var coreButtons = { | ||
42 | + showDeviceView: { | ||
43 | + gid: 'switch', | ||
44 | + tt: 'Show Device View', | ||
45 | + path: 'device' | ||
46 | + }, | ||
47 | + showFlowView: { | ||
48 | + gid: 'flowTable', | ||
49 | + tt: 'Show Flow View for this Device', | ||
50 | + path: 'flow' | ||
51 | + }, | ||
52 | + showPortView: { | ||
53 | + gid: 'portTable', | ||
54 | + tt: 'Show Port View for this Device', | ||
55 | + path: 'port' | ||
56 | + }, | ||
57 | + showGroupView: { | ||
58 | + gid: 'groupTable', | ||
59 | + tt: 'Show Group View for this Device', | ||
60 | + path: 'group' | ||
61 | + }, | ||
62 | + showMeterView: { | ||
63 | + gid: 'meterTable', | ||
64 | + tt: 'Show Meter View for this Device', | ||
65 | + path: 'meter' | ||
66 | + } | ||
67 | + }; | ||
68 | + | ||
69 | + function init() { | ||
70 | + | ||
71 | + bindHandlers(); | ||
72 | + | ||
73 | + var options = angular.extend({}, panelOpts, { | ||
74 | + class: className | ||
75 | + }); | ||
76 | + | ||
77 | + detailsPanel = new Panel(id, options); | ||
78 | + detailsPanel.p.classed(className, true); | ||
79 | + } | ||
80 | + | ||
81 | + function addProp(tbody, label, value) { | ||
82 | + var tr = tbody.append('tr'), | ||
83 | + lab; | ||
84 | + if (typeof label === 'string') { | ||
85 | + lab = label.replace(/_/g, ' '); | ||
86 | + } else { | ||
87 | + lab = label; | ||
88 | + } | ||
89 | + | ||
90 | + function addCell(cls, txt) { | ||
91 | + tr.append('td').attr('class', cls).html(txt); | ||
92 | + } | ||
93 | + addCell('label', lab + ' :'); | ||
94 | + addCell('value', value); | ||
95 | + } | ||
96 | + | ||
97 | + function addSep(tbody) { | ||
98 | + tbody.append('tr').append('td').attr('colspan', 2).append('hr'); | ||
99 | + } | ||
100 | + | ||
101 | + function listProps(tbody, data) { | ||
102 | + data.propOrder.forEach(function (p) { | ||
103 | + if (p === '-') { | ||
104 | + addSep(tbody); | ||
105 | + } else { | ||
106 | + addProp(tbody, p, data.props[p]); | ||
107 | + } | ||
108 | + }); | ||
109 | + } | ||
110 | + | ||
111 | + function addBtnFooter() { | ||
112 | + detailsPanel.appendToFooter('hr'); | ||
113 | + detailsPanel.appendToFooter('div').classed('actionBtns', true); | ||
114 | + } | ||
115 | + | ||
116 | + function addAction(o) { | ||
117 | + var btnDiv = d3.select('#' + id) | ||
118 | + .select('.actionBtns') | ||
119 | + .append('div') | ||
120 | + .classed('actionBtn', true); | ||
121 | + bs.button(btnDiv, id + '-' + o.id, o.gid, o.cb, o.tt); | ||
122 | + } | ||
123 | + | ||
124 | + function installButtons(buttons, data, devId) { | ||
125 | + buttons.forEach(function (id) { | ||
126 | + var btn = coreButtons[id], | ||
127 | + gid = btn && btn.gid, | ||
128 | + tt = btn && btn.tt, | ||
129 | + path = btn && btn.path; | ||
130 | + | ||
131 | + if (btn) { | ||
132 | + addAction({ | ||
133 | + id: 'core-' + id, | ||
134 | + gid: gid, | ||
135 | + tt: tt, | ||
136 | + cb: function () { ns.navTo(path, { devId: devId }); } | ||
137 | + }); | ||
138 | + } | ||
139 | + // else if (btn = _getButtonDef(id, data)) { | ||
140 | + // addAction(btn); | ||
141 | + // } | ||
142 | + }); | ||
143 | + } | ||
144 | + | ||
145 | + function renderSingle(data) { | ||
146 | + | ||
147 | + detailsPanel.emptyRegions(); | ||
148 | + | ||
149 | + var svg = detailsPanel.appendToHeader('div') | ||
150 | + .classed('icon clickable', true) | ||
151 | + .append('svg'), | ||
152 | + title = detailsPanel.appendToHeader('h2') | ||
153 | + .classed('clickable', true), | ||
154 | + table = detailsPanel.appendToBody('table'), | ||
155 | + tbody = table.append('tbody'), | ||
156 | + navFn; | ||
157 | + | ||
158 | + gs.addGlyph(svg, (data.type || 'unknown'), 26); | ||
159 | + title.text(data.title); | ||
160 | + | ||
161 | + // // only add navigation when displaying a device | ||
162 | + // if (isDevice[data.type]) { | ||
163 | + // navFn = function () { | ||
164 | + // ns.navTo(devPath, { devId: data.id }); | ||
165 | + // }; | ||
166 | + // | ||
167 | + // svg.on('click', navFn); | ||
168 | + // title.on('click', navFn); | ||
169 | + // } | ||
170 | + | ||
171 | + listProps(tbody, data); | ||
172 | + addBtnFooter(); | ||
173 | + } | ||
174 | + | ||
175 | + | ||
176 | + function bindHandlers() { | ||
177 | + wss.bindHandlers(handlerMap); | ||
178 | + } | ||
179 | + | ||
180 | + function updateDetails(id, nodeType) { | ||
181 | + wss.sendEvent('requestDetails', { | ||
182 | + id: id, | ||
183 | + class: nodeType | ||
184 | + }); | ||
185 | + } | ||
186 | + | ||
187 | + function showDetails(data) { | ||
188 | + var buttons = fs.isA(data.buttons) || []; | ||
189 | + renderSingle(data); | ||
190 | + installButtons(buttons, data, data.id); | ||
191 | + } | ||
192 | + | ||
193 | + function toggle() { | ||
194 | + var on = detailsPanel.p.toggle(), | ||
195 | + verb = on ? 'Show' : 'Hide'; | ||
196 | + flash.flash(verb + ' Summary Panel'); | ||
197 | + } | ||
198 | + | ||
199 | + function show() { | ||
200 | + detailsPanel.p.show(); | ||
201 | + } | ||
202 | + | ||
203 | + function hide() { | ||
204 | + detailsPanel.p.hide(); | ||
205 | + } | ||
206 | + | ||
207 | + function destroy() { | ||
208 | + wss.unbindHandlers(handlerMap); | ||
209 | + detailsPanel.destroy(); | ||
210 | + } | ||
211 | + | ||
212 | + angular.module('ovTopo2') | ||
213 | + .factory('Topo2DeviceDetailsPanel', | ||
214 | + ['Topo2PanelService', 'GlyphService', 'WebSocketService', 'FlashService', | ||
215 | + 'ButtonService', 'FnService', 'NavService', | ||
216 | + function (_ps_, _gs_, _wss_, _flash_, _bs_, _fs_, _ns_) { | ||
217 | + | ||
218 | + Panel = _ps_; | ||
219 | + gs = _gs_; | ||
220 | + wss = _wss_; | ||
221 | + flash = _flash_; | ||
222 | + bs = _bs_; | ||
223 | + fs = _fs_; | ||
224 | + ns = _ns_; | ||
225 | + | ||
226 | + return { | ||
227 | + init: init, | ||
228 | + updateDetails: updateDetails, | ||
229 | + | ||
230 | + toggle: toggle, | ||
231 | + show: show, | ||
232 | + hide: hide, | ||
233 | + destroy: destroy | ||
234 | + }; | ||
235 | + } | ||
236 | + ]); | ||
237 | +})(); |
... | @@ -190,18 +190,49 @@ | ... | @@ -190,18 +190,49 @@ |
190 | 190 | ||
191 | // ========================== Main Service Definition | 191 | // ========================== Main Service Definition |
192 | 192 | ||
193 | + function update(elements) { | ||
194 | + angular.forEach(elements, function (el) { | ||
195 | + el.update(); | ||
196 | + }); | ||
197 | + } | ||
198 | + | ||
193 | function updateNodes() { | 199 | function updateNodes() { |
194 | - var allNodes = t2rs.regionNodes(); | 200 | + update(t2rs.regionNodes()); |
195 | - angular.forEach(allNodes, function (node) { | 201 | + } |
196 | - node.update(); | 202 | + |
203 | + function updateLinks() { | ||
204 | + update(t2rs.regionLinks()); | ||
205 | + } | ||
206 | + | ||
207 | + function resetAllLocations() { | ||
208 | + var nodes = t2rs.regionNodes(); | ||
209 | + | ||
210 | + angular.forEach(nodes, function (node) { | ||
211 | + node.resetPosition(); | ||
212 | + }); | ||
213 | + | ||
214 | + t2ls.update(); | ||
215 | + t2ls.tick(); | ||
216 | + } | ||
217 | + | ||
218 | + function unpin() { | ||
219 | + var hovered = t2rs.filterRegionNodes(function (model) { | ||
220 | + return model.get('hovered'); | ||
221 | + }); | ||
222 | + | ||
223 | + angular.forEach(hovered, function (model) { | ||
224 | + model.fixed = false; | ||
225 | + model.el.classed('fixed', false); | ||
197 | }); | 226 | }); |
198 | } | 227 | } |
199 | 228 | ||
200 | angular.module('ovTopo2') | 229 | angular.module('ovTopo2') |
201 | .factory('Topo2ForceService', | 230 | .factory('Topo2ForceService', |
202 | - ['$log', 'WebSocketService', 'Topo2InstanceService', 'Topo2RegionService', | 231 | + ['$log', 'WebSocketService', 'Topo2InstanceService', |
203 | - 'Topo2LayoutService', 'Topo2ViewService', 'Topo2BreadcrumbService', 'Topo2ZoomService', | 232 | + 'Topo2RegionService', 'Topo2LayoutService', 'Topo2ViewService', |
204 | - function (_$log_, _wss_, _t2is_, _t2rs_, _t2ls_, _t2vs_, _t2bcs_, zoomService) { | 233 | + 'Topo2BreadcrumbService', 'Topo2ZoomService', |
234 | + function (_$log_, _wss_, _t2is_, _t2rs_, _t2ls_, | ||
235 | + _t2vs_, _t2bcs_, zoomService) { | ||
205 | 236 | ||
206 | $log = _$log_; | 237 | $log = _$log_; |
207 | wss = _wss_; | 238 | wss = _wss_; |
... | @@ -238,7 +269,10 @@ | ... | @@ -238,7 +269,10 @@ |
238 | showMastership: showMastership, | 269 | showMastership: showMastership, |
239 | topo2PeerRegions: topo2PeerRegions, | 270 | topo2PeerRegions: topo2PeerRegions, |
240 | 271 | ||
241 | - updateNodes: updateNodes | 272 | + updateNodes: updateNodes, |
273 | + updateLinks: updateLinks, | ||
274 | + resetAllLocations: resetAllLocations, | ||
275 | + unpin: unpin | ||
242 | }; | 276 | }; |
243 | }]); | 277 | }]); |
244 | })(); | 278 | })(); | ... | ... |
... | @@ -17,9 +17,9 @@ | ... | @@ -17,9 +17,9 @@ |
17 | (function () { | 17 | (function () { |
18 | 18 | ||
19 | // Injected Services | 19 | // Injected Services |
20 | - var ks, t2ps, t2ms, ps, t2is, t2sp; | 20 | + var ks, flash, wss, t2ps, t2ms, ps, t2is, t2sp, t2vs; |
21 | 21 | ||
22 | - var topo2ForceService; | 22 | + var t2fs; |
23 | 23 | ||
24 | // Commmands | 24 | // Commmands |
25 | var actionMap = { | 25 | var actionMap = { |
... | @@ -27,11 +27,16 @@ | ... | @@ -27,11 +27,16 @@ |
27 | G: [openMapSelection, 'Select background geo map'], | 27 | G: [openMapSelection, 'Select background geo map'], |
28 | B: [toggleMap, 'Toggle background geo map'], | 28 | B: [toggleMap, 'Toggle background geo map'], |
29 | I: [toggleInstancePanel, 'Toggle ONOS Instance Panel'], | 29 | I: [toggleInstancePanel, 'Toggle ONOS Instance Panel'], |
30 | - O: [toggleSummary, 'Toggle the Summary Panel'] | 30 | + O: [toggleSummary, 'Toggle the Summary Panel'], |
31 | + R: [resetZoom, 'Reset pan / zoom'], | ||
32 | + P: [togglePorts, 'Toggle Port Highlighting'], | ||
33 | + E: [equalizeMasters, 'Equalize mastership roles'], | ||
34 | + X: [resetAllNodeLocations, 'Reset Node Location'], | ||
35 | + U: [unpinNode, 'Unpin node (mouse over)'] | ||
31 | }; | 36 | }; |
32 | 37 | ||
33 | - function init(t2fs) { | 38 | + function init(_t2fs_) { |
34 | - topo2ForceService = t2fs; | 39 | + t2fs = _t2fs_; |
35 | bindCommands(); | 40 | bindCommands(); |
36 | } | 41 | } |
37 | 42 | ||
... | @@ -58,7 +63,7 @@ | ... | @@ -58,7 +63,7 @@ |
58 | function cycleDeviceLabels() { | 63 | function cycleDeviceLabels() { |
59 | var deviceLabelIndex = t2ps.get('dlbls') + 1; | 64 | var deviceLabelIndex = t2ps.get('dlbls') + 1; |
60 | t2ps.set('dlbls', deviceLabelIndex % 3); | 65 | t2ps.set('dlbls', deviceLabelIndex % 3); |
61 | - topo2ForceService.updateNodes(); | 66 | + t2fs.updateNodes(); |
62 | } | 67 | } |
63 | 68 | ||
64 | function openMapSelection() { | 69 | function openMapSelection() { |
... | @@ -77,17 +82,47 @@ | ... | @@ -77,17 +82,47 @@ |
77 | t2sp.toggle(); | 82 | t2sp.toggle(); |
78 | } | 83 | } |
79 | 84 | ||
85 | + function resetZoom() { | ||
86 | + t2ms.resetZoom(); | ||
87 | + flash.flash('Pan and zoom reset'); | ||
88 | + } | ||
89 | + | ||
90 | + function togglePorts(x) { | ||
91 | + updatePrefsState('porthl', t2vs.togglePortHighlights(x)); | ||
92 | + t2fs.updateLinks(); | ||
93 | + } | ||
94 | + | ||
95 | + function equalizeMasters() { | ||
96 | + wss.sendEvent('equalizeMasters'); | ||
97 | + flash.flash('Equalizing master roles'); | ||
98 | + } | ||
99 | + | ||
100 | + function resetAllNodeLocations() { | ||
101 | + t2fs.resetAllLocations(); | ||
102 | + flash.flash('Reset node locations'); | ||
103 | + } | ||
104 | + | ||
105 | + function unpinNode() { | ||
106 | + t2fs.unpin(); | ||
107 | + flash.flash('Unpin node'); | ||
108 | + } | ||
109 | + | ||
80 | angular.module('ovTopo2') | 110 | angular.module('ovTopo2') |
81 | .factory('Topo2KeyCommandService', | 111 | .factory('Topo2KeyCommandService', |
82 | - ['KeyService', 'Topo2PrefsService', 'Topo2MapService', 'PrefsService', | 112 | + ['KeyService', 'FlashService', 'WebSocketService', 'Topo2PrefsService', |
83 | - 'Topo2InstanceService', 'Topo2SummaryPanelService', | 113 | + 'Topo2MapService', 'PrefsService', 'Topo2InstanceService', |
84 | - function (_ks_, _t2ps_, _t2ms_, _ps_, _t2is_, _t2sp_) { | 114 | + 'Topo2SummaryPanelService', 'Topo2ViewService', |
115 | + function (_ks_, _flash_, _wss_, _t2ps_, _t2ms_, _ps_, _t2is_, _t2sp_, _t2vs_) { | ||
116 | + | ||
117 | + ks = _ks_; | ||
118 | + flash = _flash_; | ||
119 | + wss = _wss_; | ||
85 | t2ps = _t2ps_; | 120 | t2ps = _t2ps_; |
86 | t2ms = _t2ms_; | 121 | t2ms = _t2ms_; |
87 | t2is = _t2is_; | 122 | t2is = _t2is_; |
88 | ps = _ps_; | 123 | ps = _ps_; |
89 | - ks = _ks_; | ||
90 | t2sp = _t2sp_; | 124 | t2sp = _t2sp_; |
125 | + t2vs = _t2vs_; | ||
91 | 126 | ||
92 | return { | 127 | return { |
93 | init: init, | 128 | init: init, | ... | ... |
... | @@ -438,6 +438,7 @@ | ... | @@ -438,6 +438,7 @@ |
438 | init: init, | 438 | init: init, |
439 | createForceLayout: createForceLayout, | 439 | createForceLayout: createForceLayout, |
440 | update: update, | 440 | update: update, |
441 | + tick: tick, | ||
441 | start: start, | 442 | start: start, |
442 | 443 | ||
443 | setDimensions: setDimensions | 444 | setDimensions: setDimensions | ... | ... |
... | @@ -22,8 +22,7 @@ | ... | @@ -22,8 +22,7 @@ |
22 | (function () { | 22 | (function () { |
23 | 'use strict'; | 23 | 'use strict'; |
24 | 24 | ||
25 | - var $log; | 25 | + var $log, Collection, Model, ts, sus, t2zs, t2vs; |
26 | - var Collection, Model, ts, sus, t2zs; | ||
27 | 26 | ||
28 | var linkLabelOffset = '0.35em'; | 27 | var linkLabelOffset = '0.35em'; |
29 | 28 | ||
... | @@ -59,7 +58,6 @@ | ... | @@ -59,7 +58,6 @@ |
59 | var attrs = angular.extend({}, linkPoints, { | 58 | var attrs = angular.extend({}, linkPoints, { |
60 | key: this.get('id'), | 59 | key: this.get('id'), |
61 | class: 'link', | 60 | class: 'link', |
62 | - weight: 1, | ||
63 | srcPort: this.get('srcPort'), | 61 | srcPort: this.get('srcPort'), |
64 | tgtPort: this.get('dstPort'), | 62 | tgtPort: this.get('dstPort'), |
65 | position: { | 63 | position: { |
... | @@ -144,44 +142,47 @@ | ... | @@ -144,44 +142,47 @@ |
144 | }); | 142 | }); |
145 | 143 | ||
146 | this.el.classed('enhanced', true); | 144 | this.el.classed('enhanced', true); |
147 | - point = this.locatePortLabel(); | ||
148 | - angular.extend(point, { | ||
149 | - id: 'topo-port-tgt', | ||
150 | - num: this.get('portB') | ||
151 | - }); | ||
152 | - data.push(point); | ||
153 | 145 | ||
154 | - if (this.get('portA')) { | 146 | + if (showPort()) { |
155 | - point = this.locatePortLabel(1); | 147 | + point = this.locatePortLabel(); |
156 | angular.extend(point, { | 148 | angular.extend(point, { |
157 | - id: 'topo-port-src', | 149 | + id: 'topo-port-tgt', |
158 | - num: this.get('portA') | 150 | + num: this.get('portB') |
159 | }); | 151 | }); |
160 | data.push(point); | 152 | data.push(point); |
161 | - } | ||
162 | 153 | ||
163 | - var entering = d3.select('#topo-portLabels') | 154 | + if (this.get('portA')) { |
164 | - .selectAll('.portLabel') | 155 | + point = this.locatePortLabel(1); |
165 | - .data(data).enter().append('g') | 156 | + angular.extend(point, { |
166 | - .classed('portLabel', true) | 157 | + id: 'topo-port-src', |
167 | - .attr('id', function (d) { return d.id; }); | 158 | + num: this.get('portA') |
159 | + }); | ||
160 | + data.push(point); | ||
161 | + } | ||
162 | + | ||
163 | + var entering = d3.select('#topo-portLabels') | ||
164 | + .selectAll('.portLabel') | ||
165 | + .data(data).enter().append('g') | ||
166 | + .classed('portLabel', true) | ||
167 | + .attr('id', function (d) { return d.id; }); | ||
168 | 168 | ||
169 | - entering.each(function (d) { | 169 | + entering.each(function (d) { |
170 | - var el = d3.select(this), | 170 | + var el = d3.select(this), |
171 | - rect = el.append('rect'), | 171 | + rect = el.append('rect'), |
172 | - text = el.append('text').text(d.num); | 172 | + text = el.append('text').text(d.num); |
173 | 173 | ||
174 | - var rectSize = rectAroundText(el); | 174 | + var rectSize = rectAroundText(el); |
175 | 175 | ||
176 | - rect.attr(rectSize) | 176 | + rect.attr(rectSize) |
177 | - .attr('rx', 2) | 177 | + .attr('rx', 2) |
178 | - .attr('ry', 2); | 178 | + .attr('ry', 2); |
179 | 179 | ||
180 | - text.attr('dy', linkLabelOffset) | 180 | + text.attr('dy', linkLabelOffset) |
181 | - .attr('text-anchor', 'middle'); | 181 | + .attr('text-anchor', 'middle'); |
182 | 182 | ||
183 | - el.attr('transform', sus.translate(d.x, d.y)); | 183 | + el.attr('transform', sus.translate(d.x, d.y)); |
184 | - }); | 184 | + }); |
185 | + } | ||
185 | }, | 186 | }, |
186 | unenhance: function () { | 187 | unenhance: function () { |
187 | this.el.classed('enhanced', false); | 188 | this.el.classed('enhanced', false); |
... | @@ -248,6 +249,11 @@ | ... | @@ -248,6 +249,11 @@ |
248 | setScale: function () { | 249 | setScale: function () { |
249 | var width = linkScale(widthRatio / t2zs.scale()); | 250 | var width = linkScale(widthRatio / t2zs.scale()); |
250 | this.el.style('stroke-width', width + 'px'); | 251 | this.el.style('stroke-width', width + 'px'); |
252 | + }, | ||
253 | + update: function () { | ||
254 | + if (this.el.classed('enhanced')) { | ||
255 | + this.enhance(); | ||
256 | + } | ||
251 | } | 257 | } |
252 | }); | 258 | }); |
253 | 259 | ||
... | @@ -258,17 +264,23 @@ | ... | @@ -258,17 +264,23 @@ |
258 | return new LinkCollection(data); | 264 | return new LinkCollection(data); |
259 | } | 265 | } |
260 | 266 | ||
267 | + function showPort() { | ||
268 | + return t2vs.getPortHighlighting(); | ||
269 | + } | ||
270 | + | ||
261 | angular.module('ovTopo2') | 271 | angular.module('ovTopo2') |
262 | .factory('Topo2LinkService', | 272 | .factory('Topo2LinkService', |
263 | ['$log', 'Topo2Collection', 'Topo2Model', | 273 | ['$log', 'Topo2Collection', 'Topo2Model', |
264 | 'ThemeService', 'SvgUtilService', 'Topo2ZoomService', | 274 | 'ThemeService', 'SvgUtilService', 'Topo2ZoomService', |
265 | - | 275 | + 'Topo2ViewService', |
266 | - function (_$log_, _Collection_, _Model_, _ts_, _sus_, _t2zs_) { | 276 | + function (_$log_, _Collection_, _Model_, _ts_, _sus_, |
277 | + _t2zs_, _t2vs_) { | ||
267 | 278 | ||
268 | $log = _$log_; | 279 | $log = _$log_; |
269 | ts = _ts_; | 280 | ts = _ts_; |
270 | sus = _sus_; | 281 | sus = _sus_; |
271 | t2zs = _t2zs_; | 282 | t2zs = _t2zs_; |
283 | + t2vs = _t2vs_; | ||
272 | Collection = _Collection_; | 284 | Collection = _Collection_; |
273 | Model = _Model_; | 285 | Model = _Model_; |
274 | 286 | ... | ... |
... | @@ -29,13 +29,15 @@ | ... | @@ -29,13 +29,15 @@ |
29 | var MapSelectionDialog; | 29 | var MapSelectionDialog; |
30 | 30 | ||
31 | // internal state | 31 | // internal state |
32 | - var mapG; | 32 | + var mapG, zoomLayer, zoomer; |
33 | 33 | ||
34 | - function init(zoomLayer) { | 34 | + function init(_zoomLayer_, _zoomer_) { |
35 | - return setUpMap(zoomLayer); | 35 | + zoomLayer = _zoomLayer_; |
36 | + zoomer = _zoomer_; | ||
37 | + return setUpMap(); | ||
36 | } | 38 | } |
37 | 39 | ||
38 | - function setUpMap(zoomLayer) { | 40 | + function setUpMap() { |
39 | var prefs = currentMap(), | 41 | var prefs = currentMap(), |
40 | mapId = prefs.mapid, | 42 | mapId = prefs.mapid, |
41 | mapFilePath = prefs.mapfilepath, | 43 | mapFilePath = prefs.mapfilepath, |
... | @@ -124,6 +126,10 @@ | ... | @@ -124,6 +126,10 @@ |
124 | }).open(); | 126 | }).open(); |
125 | } | 127 | } |
126 | 128 | ||
129 | + function resetZoom() { | ||
130 | + zoomer.reset(); | ||
131 | + } | ||
132 | + | ||
127 | angular.module('ovTopo2') | 133 | angular.module('ovTopo2') |
128 | .factory('Topo2MapService', | 134 | .factory('Topo2MapService', |
129 | ['$location', 'PrefsService', 'MapService', | 135 | ['$location', 'PrefsService', 'MapService', |
... | @@ -140,7 +146,9 @@ | ... | @@ -140,7 +146,9 @@ |
140 | return { | 146 | return { |
141 | init: init, | 147 | init: init, |
142 | openMapSelection: openMapSelection, | 148 | openMapSelection: openMapSelection, |
143 | - toggle: toggle | 149 | + toggle: toggle, |
150 | + | ||
151 | + resetZoom: resetZoom | ||
144 | }; | 152 | }; |
145 | } | 153 | } |
146 | ]); | 154 | ]); | ... | ... |
... | @@ -15,18 +15,14 @@ | ... | @@ -15,18 +15,14 @@ |
15 | */ | 15 | */ |
16 | 16 | ||
17 | /* | 17 | /* |
18 | - ONOS GUI -- Topology Layout Module. | 18 | + ONOS GUI -- Topology Node Module. |
19 | - Module that contains the d3.force.layout logic | 19 | + Module that contains model for nodes within the topology |
20 | */ | 20 | */ |
21 | 21 | ||
22 | (function () { | 22 | (function () { |
23 | 'use strict'; | 23 | 'use strict'; |
24 | 24 | ||
25 | - var randomService, ps, sus, is, ts, t2mcs; | 25 | + var ps, sus, is, ts, t2mcs, t2nps, fn; |
26 | - var fn; | ||
27 | - | ||
28 | - // Internal state; | ||
29 | - var nearDist = 15; | ||
30 | 26 | ||
31 | var devIconDim = 36, | 27 | var devIconDim = 36, |
32 | devIconDimMin = 20, | 28 | devIconDimMin = 20, |
... | @@ -56,133 +52,56 @@ | ... | @@ -56,133 +52,56 @@ |
56 | dColTheme[ts.theme()][otag]; | 52 | dColTheme[ts.theme()][otag]; |
57 | } | 53 | } |
58 | 54 | ||
59 | - function positionNode(node, forUpdate) { | ||
60 | - var meta = node.get('metaUi'), | ||
61 | - x = meta && meta.x, | ||
62 | - y = meta && meta.y, | ||
63 | - dim = [800, 600], | ||
64 | - xy; | ||
65 | - | ||
66 | - // If the device contains explicit LONG/LAT data, use that to position | ||
67 | - if (setLongLat(node)) { | ||
68 | - // Indicate we want to update cached meta data... | ||
69 | - return true; | ||
70 | - } | ||
71 | - | ||
72 | - // else if we have [x,y] cached in meta data, use that... | ||
73 | - if (x !== undefined && y !== undefined) { | ||
74 | - node.fixed = true; | ||
75 | - node.px = node.x = x; | ||
76 | - node.py = node.y = y; | ||
77 | - return; | ||
78 | - } | ||
79 | - | ||
80 | - // if this is a node update (not a node add).. skip randomizer | ||
81 | - if (forUpdate) { | ||
82 | - return; | ||
83 | - } | ||
84 | - | ||
85 | - // Note: Placing incoming unpinned nodes at exactly the same point | ||
86 | - // (center of the view) causes them to explode outwards when | ||
87 | - // the force layout kicks in. So, we spread them out a bit | ||
88 | - // initially, to provide a more serene layout convergence. | ||
89 | - // Additionally, if the node is a host, we place it near | ||
90 | - // the device it is connected to. | ||
91 | - | ||
92 | - function rand() { | ||
93 | - return { | ||
94 | - x: randomService.randDim(dim[0]), | ||
95 | - y: randomService.randDim(dim[1]) | ||
96 | - }; | ||
97 | - } | ||
98 | - | ||
99 | - function near(node) { | ||
100 | - return { | ||
101 | - x: node.x + nearDist + randomService.spread(nearDist), | ||
102 | - y: node.y + nearDist + randomService.spread(nearDist) | ||
103 | - }; | ||
104 | - } | ||
105 | - | ||
106 | - function getDevice(cp) { | ||
107 | - return rand(); | ||
108 | - } | ||
109 | - | ||
110 | - xy = (node.class === 'host') ? near(getDevice(node.cp)) : rand(); | ||
111 | - | ||
112 | - if (node.class === 'sub-region') { | ||
113 | - xy = rand(); | ||
114 | - node.x = node.px = xy.x; | ||
115 | - node.y = node.py = xy.y; | ||
116 | - } | ||
117 | - angular.extend(node, xy); | ||
118 | - } | ||
119 | - | ||
120 | - function setLongLat(el) { | ||
121 | - var loc = el.get('location'), | ||
122 | - coord; | ||
123 | - | ||
124 | - if (loc && loc.type === 'lnglat') { | ||
125 | - | ||
126 | - if (loc.lat === 0 && loc.lng === 0) { | ||
127 | - return false; | ||
128 | - } | ||
129 | - | ||
130 | - coord = coordFromLngLat(loc); | ||
131 | - el.fixed = true; | ||
132 | - el.x = el.px = coord[0]; | ||
133 | - el.y = el.py = coord[1]; | ||
134 | - | ||
135 | - return true; | ||
136 | - } | ||
137 | - } | ||
138 | - | ||
139 | - function coordFromLngLat(loc) { | ||
140 | - var p = t2mcs.projection(); | ||
141 | - return p ? p([loc.lng, loc.lat]) : [0, 0]; | ||
142 | - } | ||
143 | - | ||
144 | angular.module('ovTopo2') | 55 | angular.module('ovTopo2') |
145 | .factory('Topo2NodeModel', | 56 | .factory('Topo2NodeModel', |
146 | - ['Topo2Model', 'FnService', 'RandomService', 'Topo2PrefsService', | 57 | + ['Topo2Model', 'FnService', 'Topo2PrefsService', |
147 | 'SvgUtilService', 'IconService', 'ThemeService', | 58 | 'SvgUtilService', 'IconService', 'ThemeService', |
148 | - 'Topo2MapConfigService', 'Topo2ZoomService', | 59 | + 'Topo2MapConfigService', 'Topo2ZoomService', 'Topo2NodePositionService', |
149 | - function (Model, _fn_, _RandomService_, _ps_, _sus_, _is_, _ts_, | 60 | + function (Model, _fn_, _ps_, _sus_, _is_, _ts_, |
150 | - _t2mcs_, zoomService) { | 61 | + _t2mcs_, zoomService, _t2nps_) { |
151 | 62 | ||
152 | - randomService = _RandomService_; | ||
153 | ts = _ts_; | 63 | ts = _ts_; |
154 | fn = _fn_; | 64 | fn = _fn_; |
155 | ps = _ps_; | 65 | ps = _ps_; |
156 | sus = _sus_; | 66 | sus = _sus_; |
157 | is = _is_; | 67 | is = _is_; |
158 | t2mcs = _t2mcs_; | 68 | t2mcs = _t2mcs_; |
69 | + t2nps = _t2nps_; | ||
159 | 70 | ||
160 | return Model.extend({ | 71 | return Model.extend({ |
161 | initialize: function () { | 72 | initialize: function () { |
162 | - this.set('class', this.nodeType); | ||
163 | - this.set('svgClass', this.svgClassName()); | ||
164 | this.node = this.createNode(); | 73 | this.node = this.createNode(); |
74 | + this._events = { | ||
75 | + 'mouseover': 'mouseoverHandler', | ||
76 | + 'mouseout': 'mouseoutHandler' | ||
77 | + }; | ||
165 | }, | 78 | }, |
166 | createNode: function () { | 79 | createNode: function () { |
167 | - this.set('class', this.nodeType); | ||
168 | this.set('svgClass', this.svgClassName()); | 80 | this.set('svgClass', this.svgClassName()); |
169 | - positionNode(this); | 81 | + t2nps.positionNode(this); |
170 | return this; | 82 | return this; |
171 | }, | 83 | }, |
172 | setUpEvents: function () { | 84 | setUpEvents: function () { |
173 | - var _this = this; | 85 | + var _this = this, |
174 | - angular.forEach(this.events, function (handler, key) { | 86 | + events = angular.extend({}, this._events, this.events); |
87 | + angular.forEach(events, function (handler, key) { | ||
175 | _this.el.on(key, _this[handler].bind(_this)); | 88 | _this.el.on(key, _this[handler].bind(_this)); |
176 | }); | 89 | }); |
177 | }, | 90 | }, |
91 | + mouseoverHandler: function () { | ||
92 | + this.set('hovered', true); | ||
93 | + }, | ||
94 | + mouseoutHandler: function () { | ||
95 | + this.set('hovered', false); | ||
96 | + }, | ||
178 | icon: function () { | 97 | icon: function () { |
179 | return 'unknown'; | 98 | return 'unknown'; |
180 | }, | 99 | }, |
181 | label: function () { | 100 | label: function () { |
182 | var props = this.get('props'), | 101 | var props = this.get('props'), |
183 | id = this.get('id'), | 102 | id = this.get('id'), |
184 | - friendlyName = props ? props.name : id, | 103 | + friendlyName = props && props.name ? props.name : id, |
185 | - labels = ['', friendlyName, id], | 104 | + labels = ['', friendlyName || id, id], |
186 | nli = ps.get('dlbls'), | 105 | nli = ps.get('dlbls'), |
187 | idx = (nli < labels.length) ? nli : 0; | 106 | idx = (nli < labels.length) ? nli : 0; |
188 | 107 | ||
... | @@ -197,7 +116,8 @@ | ... | @@ -197,7 +116,8 @@ |
197 | return box.width + labelPad * 2; | 116 | return box.width + labelPad * 2; |
198 | }, | 117 | }, |
199 | addLabelElements: function (label) { | 118 | addLabelElements: function (label) { |
200 | - var rect = this.el.append('rect'); | 119 | + var rect = this.el.append('rect') |
120 | + .attr('class', 'node-container'); | ||
201 | var glythRect = this.el.append('rect') | 121 | var glythRect = this.el.append('rect') |
202 | .attr('y', -halfDevIcon) | 122 | .attr('y', -halfDevIcon) |
203 | .attr('x', -halfDevIcon) | 123 | .attr('x', -halfDevIcon) |
... | @@ -243,7 +163,8 @@ | ... | @@ -243,7 +163,8 @@ |
243 | this.nodeType, | 163 | this.nodeType, |
244 | this.get('type'), | 164 | this.get('type'), |
245 | { | 165 | { |
246 | - online: this.get('online') | 166 | + online: this.get('online'), |
167 | + selected: this.get('selected') | ||
247 | } | 168 | } |
248 | ); | 169 | ); |
249 | }, | 170 | }, |
... | @@ -251,6 +172,9 @@ | ... | @@ -251,6 +172,9 @@ |
251 | var p = t2mcs.projection(); | 172 | var p = t2mcs.projection(); |
252 | return p ? p.invert(coord) : [0, 0]; | 173 | return p ? p.invert(coord) : [0, 0]; |
253 | }, | 174 | }, |
175 | + resetPosition: function () { | ||
176 | + t2nps.setLongLat(this); | ||
177 | + }, | ||
254 | update: function () { | 178 | update: function () { |
255 | this.updateLabel(); | 179 | this.updateLabel(); |
256 | }, | 180 | }, |
... | @@ -281,8 +205,8 @@ | ... | @@ -281,8 +205,8 @@ |
281 | multipler = devIconDimMax / (dim * zoomService.scale()); | 205 | multipler = devIconDimMax / (dim * zoomService.scale()); |
282 | } | 206 | } |
283 | 207 | ||
284 | - | 208 | + this.el.selectAll('*') |
285 | - this.el.selectAll('*').style('transform', 'scale(' + multipler + ')'); | 209 | + .style('transform', 'scale(' + multipler + ')'); |
286 | }, | 210 | }, |
287 | render: function () { | 211 | render: function () { |
288 | var node = this.el, | 212 | var node = this.el, |
... | @@ -293,7 +217,8 @@ | ... | @@ -293,7 +217,8 @@ |
293 | // Label | 217 | // Label |
294 | var labelElements = this.addLabelElements(label); | 218 | var labelElements = this.addLabelElements(label); |
295 | labelWidth = label ? this.computeLabelWidth(node) : 0; | 219 | labelWidth = label ? this.computeLabelWidth(node) : 0; |
296 | - labelElements.rect.attr(this.labelBox(devIconDim, labelWidth)); | 220 | + labelElements.rect |
221 | + .attr(this.labelBox(devIconDim, labelWidth)); | ||
297 | 222 | ||
298 | // Icon | 223 | // Icon |
299 | glyph = is.addDeviceIcon(node, glyphId, devIconDim); | 224 | glyph = is.addDeviceIcon(node, glyphId, devIconDim); | ... | ... |
1 | +/* | ||
2 | + * Copyright 2016-present Open Networking Laboratory | ||
3 | + * | ||
4 | + * Licensed under the Apache License, Version 2.0 (the "License"); | ||
5 | + * you may not use this file except in compliance with the License. | ||
6 | + * You may obtain a copy of the License at | ||
7 | + * | ||
8 | + * http://www.apache.org/licenses/LICENSE-2.0 | ||
9 | + * | ||
10 | + * Unless required by applicable law or agreed to in writing, software | ||
11 | + * distributed under the License is distributed on an "AS IS" BASIS, | ||
12 | + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
13 | + * See the License for the specific language governing permissions and | ||
14 | + * limitations under the License. | ||
15 | + */ | ||
16 | + | ||
17 | +/* | ||
18 | + ONOS GUI -- Topology Node Position Module. | ||
19 | + Module that helps position nodes in the topology | ||
20 | + */ | ||
21 | + | ||
22 | +(function () { | ||
23 | + 'use strict'; | ||
24 | + | ||
25 | + // Injected vars | ||
26 | + var rs, t2mcs; | ||
27 | + | ||
28 | + // Internal state; | ||
29 | + var nearDist = 15; | ||
30 | + | ||
31 | + function positionNode(node, forUpdate) { | ||
32 | + var meta = node.get('metaUi'), | ||
33 | + x = meta && meta.x, | ||
34 | + y = meta && meta.y, | ||
35 | + dim = [800, 600], | ||
36 | + xy; | ||
37 | + | ||
38 | + // If the device contains explicit LONG/LAT data, use that to position | ||
39 | + if (setLongLat(node)) { | ||
40 | + // Indicate we want to update cached meta data... | ||
41 | + return true; | ||
42 | + } | ||
43 | + | ||
44 | + // else if we have [x,y] cached in meta data, use that... | ||
45 | + if (x !== undefined && y !== undefined) { | ||
46 | + node.fixed = true; | ||
47 | + node.px = node.x = x; | ||
48 | + node.py = node.y = y; | ||
49 | + return; | ||
50 | + } | ||
51 | + | ||
52 | + // if this is a node update (not a node add).. skip randomizer | ||
53 | + if (forUpdate) { | ||
54 | + return; | ||
55 | + } | ||
56 | + | ||
57 | + // Note: Placing incoming unpinned nodes at exactly the same point | ||
58 | + // (center of the view) causes them to explode outwards when | ||
59 | + // the force layout kicks in. So, we spread them out a bit | ||
60 | + // initially, to provide a more serene layout convergence. | ||
61 | + // Additionally, if the node is a host, we place it near | ||
62 | + // the device it is connected to. | ||
63 | + | ||
64 | + function rand() { | ||
65 | + return { | ||
66 | + x: rs.randDim(dim[0]), | ||
67 | + y: rs.randDim(dim[1]) | ||
68 | + }; | ||
69 | + } | ||
70 | + | ||
71 | + function near(node) { | ||
72 | + return { | ||
73 | + x: node.x + nearDist + rs.spread(nearDist), | ||
74 | + y: node.y + nearDist + rs.spread(nearDist) | ||
75 | + }; | ||
76 | + } | ||
77 | + | ||
78 | + function getDevice(cp) { | ||
79 | + return rand(); | ||
80 | + } | ||
81 | + | ||
82 | + xy = (node.class === 'host') ? near(getDevice(node.cp)) : rand(); | ||
83 | + | ||
84 | + if (node.class === 'sub-region') { | ||
85 | + xy = rand(); | ||
86 | + node.x = node.px = xy.x; | ||
87 | + node.y = node.py = xy.y; | ||
88 | + } | ||
89 | + angular.extend(node, xy); | ||
90 | + } | ||
91 | + | ||
92 | + function setLongLat(el) { | ||
93 | + var loc = el.get('location'), | ||
94 | + coord; | ||
95 | + | ||
96 | + if (loc && loc.type === 'lnglat') { | ||
97 | + | ||
98 | + if (loc.lat === 0 && loc.lng === 0) { | ||
99 | + return false; | ||
100 | + } | ||
101 | + | ||
102 | + coord = coordFromLngLat(loc); | ||
103 | + el.fixed = true; | ||
104 | + el.x = el.px = coord[0]; | ||
105 | + el.y = el.py = coord[1]; | ||
106 | + | ||
107 | + return true; | ||
108 | + } | ||
109 | + } | ||
110 | + | ||
111 | + function coordFromLngLat(loc) { | ||
112 | + var p = t2mcs.projection(); | ||
113 | + return p ? p([loc.lng, loc.lat]) : [0, 0]; | ||
114 | + } | ||
115 | + | ||
116 | + angular.module('ovTopo2') | ||
117 | + .factory('Topo2NodePositionService', | ||
118 | + ['RandomService', | ||
119 | + function (_rs_, _t2mcs_) { | ||
120 | + | ||
121 | + rs = _rs_; | ||
122 | + t2mcs = _t2mcs_; | ||
123 | + | ||
124 | + return { | ||
125 | + positionNode: positionNode, | ||
126 | + setLongLat: setLongLat | ||
127 | + }; | ||
128 | + } | ||
129 | + ]); | ||
130 | +})(); |
... | @@ -29,7 +29,9 @@ | ... | @@ -29,7 +29,9 @@ |
29 | this.p = ps.createPanel(this.id, options); | 29 | this.p = ps.createPanel(this.id, options); |
30 | this.setup(); | 30 | this.setup(); |
31 | 31 | ||
32 | - this.p.show(); | 32 | + if (options.show) { |
33 | + this.p.show(); | ||
34 | + } | ||
33 | }; | 35 | }; |
34 | 36 | ||
35 | Panel.prototype = { | 37 | Panel.prototype = { |
... | @@ -59,8 +61,8 @@ | ... | @@ -59,8 +61,8 @@ |
59 | this.body.selectAll("*").remove(); | 61 | this.body.selectAll("*").remove(); |
60 | this.footer.selectAll("*").remove(); | 62 | this.footer.selectAll("*").remove(); |
61 | }, | 63 | }, |
62 | - destory: function () { | 64 | + destroy: function () { |
63 | - ps.destroy(this.id); | 65 | + ps.destroyPanel(this.id); |
64 | } | 66 | } |
65 | }; | 67 | }; |
66 | 68 | ... | ... |
... | @@ -80,6 +80,11 @@ | ... | @@ -80,6 +80,11 @@ |
80 | return []; | 80 | return []; |
81 | } | 81 | } |
82 | 82 | ||
83 | + function filterRegionNodes(predicate) { | ||
84 | + var nodes = regionNodes(); | ||
85 | + return _.filter(nodes, predicate); | ||
86 | + } | ||
87 | + | ||
83 | function regionLinks() { | 88 | function regionLinks() { |
84 | return (region) ? region.get('links').models : []; | 89 | return (region) ? region.get('links').models : []; |
85 | } | 90 | } |
... | @@ -105,6 +110,7 @@ | ... | @@ -105,6 +110,7 @@ |
105 | addRegion: addRegion, | 110 | addRegion: addRegion, |
106 | regionNodes: regionNodes, | 111 | regionNodes: regionNodes, |
107 | regionLinks: regionLinks, | 112 | regionLinks: regionLinks, |
113 | + filterRegionNodes: filterRegionNodes, | ||
108 | 114 | ||
109 | getSubRegions: t2sr.getSubRegions | 115 | getSubRegions: t2sr.getSubRegions |
110 | }; | 116 | }; | ... | ... |
... | @@ -29,8 +29,12 @@ | ... | @@ -29,8 +29,12 @@ |
29 | var summaryPanel, summaryData; | 29 | var summaryPanel, summaryData; |
30 | 30 | ||
31 | // configuration | 31 | // configuration |
32 | - var id = 'topo-p-summary', | 32 | + var id = 'topo2-p-summary', |
33 | className = 'topo-p', | 33 | className = 'topo-p', |
34 | + panelOpts = { | ||
35 | + show: true, | ||
36 | + width: 260 // summary and detail panel width | ||
37 | + }, | ||
34 | handlerMap = { | 38 | handlerMap = { |
35 | showSummary: handleSummaryData | 39 | showSummary: handleSummaryData |
36 | }; | 40 | }; |
... | @@ -40,10 +44,12 @@ | ... | @@ -40,10 +44,12 @@ |
40 | bindHandlers(); | 44 | bindHandlers(); |
41 | wss.sendEvent('requestSummary'); | 45 | wss.sendEvent('requestSummary'); |
42 | 46 | ||
43 | - summaryPanel = new Panel(id, { | 47 | + var options = angular.extend({}, panelOpts, { |
44 | class: className | 48 | class: className |
45 | }); | 49 | }); |
46 | 50 | ||
51 | + summaryPanel = new Panel(id, options); | ||
52 | + | ||
47 | summaryPanel.p.classed(className, true); | 53 | summaryPanel.p.classed(className, true); |
48 | } | 54 | } |
49 | 55 | ||
... | @@ -107,6 +113,11 @@ | ... | @@ -107,6 +113,11 @@ |
107 | flash.flash(verb + ' Summary Panel'); | 113 | flash.flash(verb + ' Summary Panel'); |
108 | } | 114 | } |
109 | 115 | ||
116 | + function destroy() { | ||
117 | + wss.unbindHandlers(handlerMap); | ||
118 | + summaryPanel.destroy(); | ||
119 | + } | ||
120 | + | ||
110 | angular.module('ovTopo2') | 121 | angular.module('ovTopo2') |
111 | .factory('Topo2SummaryPanelService', | 122 | .factory('Topo2SummaryPanelService', |
112 | ['Topo2PanelService', 'GlyphService', 'WebSocketService', 'FlashService', | 123 | ['Topo2PanelService', 'GlyphService', 'WebSocketService', 'FlashService', |
... | @@ -120,7 +131,8 @@ | ... | @@ -120,7 +131,8 @@ |
120 | return { | 131 | return { |
121 | init: init, | 132 | init: init, |
122 | 133 | ||
123 | - toggle: toggle | 134 | + toggle: toggle, |
135 | + destroy: destroy | ||
124 | }; | 136 | }; |
125 | } | 137 | } |
126 | ]); | 138 | ]); | ... | ... |
... | @@ -15,14 +15,21 @@ | ... | @@ -15,14 +15,21 @@ |
15 | */ | 15 | */ |
16 | 16 | ||
17 | /* | 17 | /* |
18 | - ONOS GUI -- Topology Layout Module. | 18 | + ONOS GUI -- Topology View Module. |
19 | - Module that contains the d3.force.layout logic | 19 | + Module that contains the topology view variables |
20 | */ | 20 | */ |
21 | 21 | ||
22 | (function () { | 22 | (function () { |
23 | 'use strict'; | 23 | 'use strict'; |
24 | 24 | ||
25 | - var dimensions; | 25 | + // Injected Services |
26 | + var flash; | ||
27 | + | ||
28 | + // Internal State | ||
29 | + var dimensions, | ||
30 | + viewOptions = { | ||
31 | + linkPortHighlighting: true | ||
32 | + }; | ||
26 | 33 | ||
27 | function newDim(_dimensions) { | 34 | function newDim(_dimensions) { |
28 | dimensions = _dimensions; | 35 | dimensions = _dimensions; |
... | @@ -32,13 +39,33 @@ | ... | @@ -32,13 +39,33 @@ |
32 | return dimensions; | 39 | return dimensions; |
33 | } | 40 | } |
34 | 41 | ||
42 | + function togglePortHighlights(x) { | ||
43 | + var kev = (x === 'keyev'), | ||
44 | + on = kev ? !viewOptions.linkPortHighlighting : Boolean(x), | ||
45 | + what = on ? 'Enable' : 'Disable'; | ||
46 | + | ||
47 | + viewOptions.linkPortHighlighting = on; | ||
48 | + flash.flash(what + ' port highlighting'); | ||
49 | + return on; | ||
50 | + } | ||
51 | + | ||
52 | + function getPortHighlighting() { | ||
53 | + return viewOptions.linkPortHighlighting; | ||
54 | + } | ||
55 | + | ||
35 | angular.module('ovTopo2') | 56 | angular.module('ovTopo2') |
36 | .factory('Topo2ViewService', | 57 | .factory('Topo2ViewService', |
37 | - [ | 58 | + ['FlashService', |
38 | - function () { | 59 | + function (_flash_) { |
60 | + | ||
61 | + flash = _flash_; | ||
62 | + | ||
39 | return { | 63 | return { |
40 | newDim: newDim, | 64 | newDim: newDim, |
41 | - getDimensions: getDimensions | 65 | + getDimensions: getDimensions, |
66 | + | ||
67 | + togglePortHighlights: togglePortHighlights, | ||
68 | + getPortHighlighting: getPortHighlighting | ||
42 | }; | 69 | }; |
43 | } | 70 | } |
44 | ] | 71 | ] | ... | ... |
... | @@ -40,6 +40,7 @@ | ... | @@ -40,6 +40,7 @@ |
40 | 40 | ||
41 | <script src="tp/Chart.min.js"></script> | 41 | <script src="tp/Chart.min.js"></script> |
42 | <script src="tp/angular-chart.min.js"></script> | 42 | <script src="tp/angular-chart.min.js"></script> |
43 | + <script src="tp/lodash.min.js"></script> | ||
43 | 44 | ||
44 | <!-- {INJECTED-USER-START} --> | 45 | <!-- {INJECTED-USER-START} --> |
45 | <!-- {INJECTED-USER-END} --> | 46 | <!-- {INJECTED-USER-END} --> |
... | @@ -132,6 +133,7 @@ | ... | @@ -132,6 +133,7 @@ |
132 | <script src="app/view/topo2/topo2D3.js"></script> | 133 | <script src="app/view/topo2/topo2D3.js"></script> |
133 | <script src="app/view/topo2/topo2Dialog.js"></script> | 134 | <script src="app/view/topo2/topo2Dialog.js"></script> |
134 | <script src="app/view/topo2/topo2Device.js"></script> | 135 | <script src="app/view/topo2/topo2Device.js"></script> |
136 | + <script src="app/view/topo2/topo2DeviceDetailsPanel.js"></script> | ||
135 | <script src="app/view/topo2/topo2Event.js"></script> | 137 | <script src="app/view/topo2/topo2Event.js"></script> |
136 | <script src="app/view/topo2/topo2Force.js"></script> | 138 | <script src="app/view/topo2/topo2Force.js"></script> |
137 | <script src="app/view/topo2/topo2Host.js"></script> | 139 | <script src="app/view/topo2/topo2Host.js"></script> |
... | @@ -145,6 +147,7 @@ | ... | @@ -145,6 +147,7 @@ |
145 | <script src="app/view/topo2/topo2MapDialog.js"></script> | 147 | <script src="app/view/topo2/topo2MapDialog.js"></script> |
146 | <script src="app/view/topo2/topo2Model.js"></script> | 148 | <script src="app/view/topo2/topo2Model.js"></script> |
147 | <script src="app/view/topo2/topo2NodeModel.js"></script> | 149 | <script src="app/view/topo2/topo2NodeModel.js"></script> |
150 | + <script src="app/view/topo2/topo2NodePosition.js"></script> | ||
148 | <script src="app/view/topo2/topo2Panel.js"></script> | 151 | <script src="app/view/topo2/topo2Panel.js"></script> |
149 | <script src="app/view/topo2/topo2Prefs.js"></script> | 152 | <script src="app/view/topo2/topo2Prefs.js"></script> |
150 | <script src="app/view/topo2/topo2Region.js"></script> | 153 | <script src="app/view/topo2/topo2Region.js"></script> | ... | ... |
web/gui/src/main/webapp/tp/lodash.min.js
0 → 100644
1 | +/** | ||
2 | + * @license | ||
3 | + * lodash lodash.com/license | Underscore.js 1.8.3 underscorejs.org/LICENSE | ||
4 | + */ | ||
5 | +;(function(){function t(t,n){return t.set(n[0],n[1]),t}function n(t,n){return t.add(n),t}function r(t,n,r){switch(r.length){case 0:return t.call(n);case 1:return t.call(n,r[0]);case 2:return t.call(n,r[0],r[1]);case 3:return t.call(n,r[0],r[1],r[2])}return t.apply(n,r)}function e(t,n,r,e){for(var u=-1,i=t?t.length:0;++u<i;){var o=t[u];n(e,o,r(o),t)}return e}function u(t,n){for(var r=-1,e=t?t.length:0;++r<e&&false!==n(t[r],r,t););return t}function i(t,n){for(var r=t?t.length:0;r--&&false!==n(t[r],r,t);); | ||
6 | +return t}function o(t,n){for(var r=-1,e=t?t.length:0;++r<e;)if(!n(t[r],r,t))return false;return true}function f(t,n){for(var r=-1,e=t?t.length:0,u=0,i=[];++r<e;){var o=t[r];n(o,r,t)&&(i[u++]=o)}return i}function c(t,n){return!(!t||!t.length)&&-1<d(t,n,0)}function a(t,n,r){for(var e=-1,u=t?t.length:0;++e<u;)if(r(n,t[e]))return true;return false}function l(t,n){for(var r=-1,e=t?t.length:0,u=Array(e);++r<e;)u[r]=n(t[r],r,t);return u}function s(t,n){for(var r=-1,e=n.length,u=t.length;++r<e;)t[u+r]=n[r];return t}function h(t,n,r,e){ | ||
7 | +var u=-1,i=t?t.length:0;for(e&&i&&(r=t[++u]);++u<i;)r=n(r,t[u],u,t);return r}function p(t,n,r,e){var u=t?t.length:0;for(e&&u&&(r=t[--u]);u--;)r=n(r,t[u],u,t);return r}function _(t,n){for(var r=-1,e=t?t.length:0;++r<e;)if(n(t[r],r,t))return true;return false}function v(t,n,r){var e;return r(t,function(t,r,u){if(n(t,r,u))return e=r,false}),e}function g(t,n,r,e){var u=t.length;for(r+=e?1:-1;e?r--:++r<u;)if(n(t[r],r,t))return r;return-1}function d(t,n,r){if(n===n)t:{--r;for(var e=t.length;++r<e;)if(t[r]===n){t=r; | ||
8 | +break t}t=-1}else t=g(t,b,r);return t}function y(t,n,r,e){--r;for(var u=t.length;++r<u;)if(e(t[r],n))return r;return-1}function b(t){return t!==t}function x(t,n){var r=t?t.length:0;return r?k(t,n)/r:P}function j(t){return function(n){return null==n?F:n[t]}}function w(t){return function(n){return null==t?F:t[n]}}function m(t,n,r,e,u){return u(t,function(t,u,i){r=e?(e=false,t):n(r,t,u,i)}),r}function A(t,n){var r=t.length;for(t.sort(n);r--;)t[r]=t[r].c;return t}function k(t,n){for(var r,e=-1,u=t.length;++e<u;){ | ||
9 | +var i=n(t[e]);i!==F&&(r=r===F?i:r+i)}return r}function E(t,n){for(var r=-1,e=Array(t);++r<t;)e[r]=n(r);return e}function O(t,n){return l(n,function(n){return[n,t[n]]})}function S(t){return function(n){return t(n)}}function I(t,n){return l(n,function(n){return t[n]})}function R(t,n){return t.has(n)}function z(t,n){for(var r=-1,e=t.length;++r<e&&-1<d(n,t[r],0););return r}function W(t,n){for(var r=t.length;r--&&-1<d(n,t[r],0););return r}function B(t){return"\\"+Dt[t]}function L(t){var n=-1,r=Array(t.size); | ||
10 | +return t.forEach(function(t,e){r[++n]=[e,t]}),r}function U(t,n){return function(r){return t(n(r))}}function C(t,n){for(var r=-1,e=t.length,u=0,i=[];++r<e;){var o=t[r];o!==n&&"__lodash_placeholder__"!==o||(t[r]="__lodash_placeholder__",i[u++]=r)}return i}function M(t){var n=-1,r=Array(t.size);return t.forEach(function(t){r[++n]=t}),r}function D(t){var n=-1,r=Array(t.size);return t.forEach(function(t){r[++n]=[t,t]}),r}function T(t){if(Wt.test(t)){for(var n=Rt.lastIndex=0;Rt.test(t);)++n;t=n}else t=tn(t); | ||
11 | +return t}function $(t){return Wt.test(t)?t.match(Rt)||[]:t.split("")}var F,N=1/0,P=NaN,Z=[["ary",128],["bind",1],["bindKey",2],["curry",8],["curryRight",16],["flip",512],["partial",32],["partialRight",64],["rearg",256]],q=/\b__p\+='';/g,V=/\b(__p\+=)''\+/g,K=/(__e\(.*?\)|\b__t\))\+'';/g,G=/&(?:amp|lt|gt|quot|#39);/g,J=/[&<>"']/g,Y=RegExp(G.source),H=RegExp(J.source),Q=/<%-([\s\S]+?)%>/g,X=/<%([\s\S]+?)%>/g,tt=/<%=([\s\S]+?)%>/g,nt=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,rt=/^\w*$/,et=/^\./,ut=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,it=/[\\^$.*+?()[\]{}|]/g,ot=RegExp(it.source),ft=/^\s+|\s+$/g,ct=/^\s+/,at=/\s+$/,lt=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,st=/\{\n\/\* \[wrapped with (.+)\] \*/,ht=/,? & /,pt=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g,_t=/\\(\\)?/g,vt=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,gt=/\w*$/,dt=/^[-+]0x[0-9a-f]+$/i,yt=/^0b[01]+$/i,bt=/^\[object .+?Constructor\]$/,xt=/^0o[0-7]+$/i,jt=/^(?:0|[1-9]\d*)$/,wt=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,mt=/($^)/,At=/['\n\r\u2028\u2029\\]/g,kt="[\\ufe0e\\ufe0f]?(?:[\\u0300-\\u036f\\ufe20-\\ufe23\\u20d0-\\u20f0]|\\ud83c[\\udffb-\\udfff])?(?:\\u200d(?:[^\\ud800-\\udfff]|(?:\\ud83c[\\udde6-\\uddff]){2}|[\\ud800-\\udbff][\\udc00-\\udfff])[\\ufe0e\\ufe0f]?(?:[\\u0300-\\u036f\\ufe20-\\ufe23\\u20d0-\\u20f0]|\\ud83c[\\udffb-\\udfff])?)*",Et="(?:[\\u2700-\\u27bf]|(?:\\ud83c[\\udde6-\\uddff]){2}|[\\ud800-\\udbff][\\udc00-\\udfff])"+kt,Ot="(?:[^\\ud800-\\udfff][\\u0300-\\u036f\\ufe20-\\ufe23\\u20d0-\\u20f0]?|[\\u0300-\\u036f\\ufe20-\\ufe23\\u20d0-\\u20f0]|(?:\\ud83c[\\udde6-\\uddff]){2}|[\\ud800-\\udbff][\\udc00-\\udfff]|[\\ud800-\\udfff])",St=RegExp("['\u2019]","g"),It=RegExp("[\\u0300-\\u036f\\ufe20-\\ufe23\\u20d0-\\u20f0]","g"),Rt=RegExp("\\ud83c[\\udffb-\\udfff](?=\\ud83c[\\udffb-\\udfff])|"+Ot+kt,"g"),zt=RegExp(["[A-Z\\xc0-\\xd6\\xd8-\\xde]?[a-z\\xdf-\\xf6\\xf8-\\xff]+(?:['\u2019](?:d|ll|m|re|s|t|ve))?(?=[\\xac\\xb1\\xd7\\xf7\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf\\u2000-\\u206f \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000]|[A-Z\\xc0-\\xd6\\xd8-\\xde]|$)|(?:[A-Z\\xc0-\\xd6\\xd8-\\xde]|[^\\ud800-\\udfff\\xac\\xb1\\xd7\\xf7\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf\\u2000-\\u206f \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000\\d+\\u2700-\\u27bfa-z\\xdf-\\xf6\\xf8-\\xffA-Z\\xc0-\\xd6\\xd8-\\xde])+(?:['\u2019](?:D|LL|M|RE|S|T|VE))?(?=[\\xac\\xb1\\xd7\\xf7\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf\\u2000-\\u206f \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000]|[A-Z\\xc0-\\xd6\\xd8-\\xde](?:[a-z\\xdf-\\xf6\\xf8-\\xff]|[^\\ud800-\\udfff\\xac\\xb1\\xd7\\xf7\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf\\u2000-\\u206f \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000\\d+\\u2700-\\u27bfa-z\\xdf-\\xf6\\xf8-\\xffA-Z\\xc0-\\xd6\\xd8-\\xde])|$)|[A-Z\\xc0-\\xd6\\xd8-\\xde]?(?:[a-z\\xdf-\\xf6\\xf8-\\xff]|[^\\ud800-\\udfff\\xac\\xb1\\xd7\\xf7\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf\\u2000-\\u206f \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000\\d+\\u2700-\\u27bfa-z\\xdf-\\xf6\\xf8-\\xffA-Z\\xc0-\\xd6\\xd8-\\xde])+(?:['\u2019](?:d|ll|m|re|s|t|ve))?|[A-Z\\xc0-\\xd6\\xd8-\\xde]+(?:['\u2019](?:D|LL|M|RE|S|T|VE))?|\\d+",Et].join("|"),"g"),Wt=RegExp("[\\u200d\\ud800-\\udfff\\u0300-\\u036f\\ufe20-\\ufe23\\u20d0-\\u20f0\\ufe0e\\ufe0f]"),Bt=/[a-z][A-Z]|[A-Z]{2,}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,Lt="Array Buffer DataView Date Error Float32Array Float64Array Function Int8Array Int16Array Int32Array Map Math Object Promise RegExp Set String Symbol TypeError Uint8Array Uint8ClampedArray Uint16Array Uint32Array WeakMap _ clearTimeout isFinite parseInt setTimeout".split(" "),Ut={}; | ||
12 | +Ut["[object Float32Array]"]=Ut["[object Float64Array]"]=Ut["[object Int8Array]"]=Ut["[object Int16Array]"]=Ut["[object Int32Array]"]=Ut["[object Uint8Array]"]=Ut["[object Uint8ClampedArray]"]=Ut["[object Uint16Array]"]=Ut["[object Uint32Array]"]=true,Ut["[object Arguments]"]=Ut["[object Array]"]=Ut["[object ArrayBuffer]"]=Ut["[object Boolean]"]=Ut["[object DataView]"]=Ut["[object Date]"]=Ut["[object Error]"]=Ut["[object Function]"]=Ut["[object Map]"]=Ut["[object Number]"]=Ut["[object Object]"]=Ut["[object RegExp]"]=Ut["[object Set]"]=Ut["[object String]"]=Ut["[object WeakMap]"]=false; | ||
13 | +var Ct={};Ct["[object Arguments]"]=Ct["[object Array]"]=Ct["[object ArrayBuffer]"]=Ct["[object DataView]"]=Ct["[object Boolean]"]=Ct["[object Date]"]=Ct["[object Float32Array]"]=Ct["[object Float64Array]"]=Ct["[object Int8Array]"]=Ct["[object Int16Array]"]=Ct["[object Int32Array]"]=Ct["[object Map]"]=Ct["[object Number]"]=Ct["[object Object]"]=Ct["[object RegExp]"]=Ct["[object Set]"]=Ct["[object String]"]=Ct["[object Symbol]"]=Ct["[object Uint8Array]"]=Ct["[object Uint8ClampedArray]"]=Ct["[object Uint16Array]"]=Ct["[object Uint32Array]"]=true, | ||
14 | +Ct["[object Error]"]=Ct["[object Function]"]=Ct["[object WeakMap]"]=false;var Mt,Dt={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},Tt=parseFloat,$t=parseInt,Ft=typeof global=="object"&&global&&global.Object===Object&&global,Nt=typeof self=="object"&&self&&self.Object===Object&&self,Pt=Ft||Nt||Function("return this")(),Zt=typeof exports=="object"&&exports&&!exports.nodeType&&exports,qt=Zt&&typeof module=="object"&&module&&!module.nodeType&&module,Vt=qt&&qt.exports===Zt,Kt=Vt&&Ft.h; | ||
15 | +t:{try{Mt=Kt&&Kt.g("util");break t}catch(t){}Mt=void 0}var Gt=Mt&&Mt.isArrayBuffer,Jt=Mt&&Mt.isDate,Yt=Mt&&Mt.isMap,Ht=Mt&&Mt.isRegExp,Qt=Mt&&Mt.isSet,Xt=Mt&&Mt.isTypedArray,tn=j("length"),nn=w({"\xc0":"A","\xc1":"A","\xc2":"A","\xc3":"A","\xc4":"A","\xc5":"A","\xe0":"a","\xe1":"a","\xe2":"a","\xe3":"a","\xe4":"a","\xe5":"a","\xc7":"C","\xe7":"c","\xd0":"D","\xf0":"d","\xc8":"E","\xc9":"E","\xca":"E","\xcb":"E","\xe8":"e","\xe9":"e","\xea":"e","\xeb":"e","\xcc":"I","\xcd":"I","\xce":"I","\xcf":"I", | ||
16 | +"\xec":"i","\xed":"i","\xee":"i","\xef":"i","\xd1":"N","\xf1":"n","\xd2":"O","\xd3":"O","\xd4":"O","\xd5":"O","\xd6":"O","\xd8":"O","\xf2":"o","\xf3":"o","\xf4":"o","\xf5":"o","\xf6":"o","\xf8":"o","\xd9":"U","\xda":"U","\xdb":"U","\xdc":"U","\xf9":"u","\xfa":"u","\xfb":"u","\xfc":"u","\xdd":"Y","\xfd":"y","\xff":"y","\xc6":"Ae","\xe6":"ae","\xde":"Th","\xfe":"th","\xdf":"ss","\u0100":"A","\u0102":"A","\u0104":"A","\u0101":"a","\u0103":"a","\u0105":"a","\u0106":"C","\u0108":"C","\u010a":"C","\u010c":"C", | ||
17 | +"\u0107":"c","\u0109":"c","\u010b":"c","\u010d":"c","\u010e":"D","\u0110":"D","\u010f":"d","\u0111":"d","\u0112":"E","\u0114":"E","\u0116":"E","\u0118":"E","\u011a":"E","\u0113":"e","\u0115":"e","\u0117":"e","\u0119":"e","\u011b":"e","\u011c":"G","\u011e":"G","\u0120":"G","\u0122":"G","\u011d":"g","\u011f":"g","\u0121":"g","\u0123":"g","\u0124":"H","\u0126":"H","\u0125":"h","\u0127":"h","\u0128":"I","\u012a":"I","\u012c":"I","\u012e":"I","\u0130":"I","\u0129":"i","\u012b":"i","\u012d":"i","\u012f":"i", | ||
18 | +"\u0131":"i","\u0134":"J","\u0135":"j","\u0136":"K","\u0137":"k","\u0138":"k","\u0139":"L","\u013b":"L","\u013d":"L","\u013f":"L","\u0141":"L","\u013a":"l","\u013c":"l","\u013e":"l","\u0140":"l","\u0142":"l","\u0143":"N","\u0145":"N","\u0147":"N","\u014a":"N","\u0144":"n","\u0146":"n","\u0148":"n","\u014b":"n","\u014c":"O","\u014e":"O","\u0150":"O","\u014d":"o","\u014f":"o","\u0151":"o","\u0154":"R","\u0156":"R","\u0158":"R","\u0155":"r","\u0157":"r","\u0159":"r","\u015a":"S","\u015c":"S","\u015e":"S", | ||
19 | +"\u0160":"S","\u015b":"s","\u015d":"s","\u015f":"s","\u0161":"s","\u0162":"T","\u0164":"T","\u0166":"T","\u0163":"t","\u0165":"t","\u0167":"t","\u0168":"U","\u016a":"U","\u016c":"U","\u016e":"U","\u0170":"U","\u0172":"U","\u0169":"u","\u016b":"u","\u016d":"u","\u016f":"u","\u0171":"u","\u0173":"u","\u0174":"W","\u0175":"w","\u0176":"Y","\u0177":"y","\u0178":"Y","\u0179":"Z","\u017b":"Z","\u017d":"Z","\u017a":"z","\u017c":"z","\u017e":"z","\u0132":"IJ","\u0133":"ij","\u0152":"Oe","\u0153":"oe","\u0149":"'n", | ||
20 | +"\u017f":"s"}),rn=w({"&":"&","<":"<",">":">",'"':""","'":"'"}),en=w({"&":"&","<":"<",">":">",""":'"',"'":"'"}),un=function w(kt){function Et(t){return fi.call(t)}function Ot(t){if(vu(t)&&!nf(t)&&!(t instanceof Dt)){if(t instanceof Mt)return t;if(ui.call(t,"__wrapped__"))return De(t)}return new Mt(t)}function Rt(){}function Mt(t,n){this.__wrapped__=t,this.__actions__=[],this.__chain__=!!n,this.__index__=0,this.__values__=F}function Dt(t){this.__wrapped__=t,this.__actions__=[], | ||
21 | +this.__dir__=1,this.__filtered__=false,this.__iteratees__=[],this.__takeCount__=4294967295,this.__views__=[]}function Ft(t){var n=-1,r=t?t.length:0;for(this.clear();++n<r;){var e=t[n];this.set(e[0],e[1])}}function Nt(t){var n=-1,r=t?t.length:0;for(this.clear();++n<r;){var e=t[n];this.set(e[0],e[1])}}function Zt(t){var n=-1,r=t?t.length:0;for(this.clear();++n<r;){var e=t[n];this.set(e[0],e[1])}}function qt(t){var n=-1,r=t?t.length:0;for(this.__data__=new Zt;++n<r;)this.add(t[n])}function Kt(t){this.size=(this.__data__=new Nt(t)).size; | ||
22 | +}function tn(t,n){var r,e=nf(t),u=!e&&tf(t),i=!e&&!u&&ef(t),o=!e&&!u&&!i&&af(t),u=(e=e||u||i||o)?E(t.length,Hu):[],f=u.length;for(r in t)!n&&!ui.call(t,r)||e&&("length"==r||i&&("offset"==r||"parent"==r)||o&&("buffer"==r||"byteLength"==r||"byteOffset"==r)||me(r,f))||u.push(r);return u}function on(t){var n=t.length;return n?t[cr(0,n-1)]:F}function fn(t,n){return Le(Cr(t),dn(n,0,t.length))}function cn(t){return Le(Cr(t))}function an(t,n,r,e){return t===F||fu(t,ti[r])&&!ui.call(e,r)?n:t}function ln(t,n,r){ | ||
23 | +(r===F||fu(t[n],r))&&(r!==F||n in t)||vn(t,n,r)}function sn(t,n,r){var e=t[n];ui.call(t,n)&&fu(e,r)&&(r!==F||n in t)||vn(t,n,r)}function hn(t,n){for(var r=t.length;r--;)if(fu(t[r][0],n))return r;return-1}function pn(t,n,r,e){return to(t,function(t,u,i){n(e,t,r(t),i)}),e}function _n(t,n){return t&&Mr(n,Iu(n),t)}function vn(t,n,r){"__proto__"==n&&xi?xi(t,n,{configurable:true,enumerable:true,value:r,writable:true}):t[n]=r}function gn(t,n){for(var r=-1,e=null==t,u=n.length,i=Zu(u);++r<u;)i[r]=e?F:Ou(t,n[r]); | ||
24 | +return i}function dn(t,n,r){return t===t&&(r!==F&&(t=t<=r?t:r),n!==F&&(t=t>=n?t:n)),t}function yn(t,n,r,e,i,o,f){var c;if(e&&(c=o?e(t,i,o,f):e(t)),c!==F)return c;if(!_u(t))return t;if(i=nf(t)){if(c=be(t),!n)return Cr(t,c)}else{var a=Et(t),l="[object Function]"==a||"[object GeneratorFunction]"==a;if(ef(t))return Rr(t,n);if("[object Object]"==a||"[object Arguments]"==a||l&&!o){if(c=xe(l?{}:t),!n)return Dr(t,_n(c,t))}else{if(!Ct[a])return o?t:{};c=je(t,a,yn,n)}}if(f||(f=new Kt),o=f.get(t))return o;f.set(t,c); | ||
25 | +var s=i?F:(r?se:Iu)(t);return u(s||t,function(u,i){s&&(i=u,u=t[i]),sn(c,i,yn(u,n,r,e,i,t,f))}),c}function bn(t){var n=Iu(t);return function(r){return xn(r,t,n)}}function xn(t,n,r){var e=r.length;if(null==t)return!e;for(t=Ju(t);e--;){var u=r[e],i=n[u],o=t[u];if(o===F&&!(u in t)||!i(o))return false}return true}function jn(t,n,r){if(typeof t!="function")throw new Qu("Expected a function");return po(function(){t.apply(F,r)},n)}function wn(t,n,r,e){var u=-1,i=c,o=true,f=t.length,s=[],h=n.length;if(!f)return s;r&&(n=l(n,S(r))), | ||
26 | +e?(i=a,o=false):200<=n.length&&(i=R,o=false,n=new qt(n));t:for(;++u<f;){var p=t[u],_=r?r(p):p,p=e||0!==p?p:0;if(o&&_===_){for(var v=h;v--;)if(n[v]===_)continue t;s.push(p)}else i(n,_,e)||s.push(p)}return s}function mn(t,n){var r=true;return to(t,function(t,e,u){return r=!!n(t,e,u)}),r}function An(t,n,r){for(var e=-1,u=t.length;++e<u;){var i=t[e],o=n(i);if(null!=o&&(f===F?o===o&&!bu(o):r(o,f)))var f=o,c=i}return c}function kn(t,n){var r=[];return to(t,function(t,e,u){n(t,e,u)&&r.push(t)}),r}function En(t,n,r,e,u){ | ||
27 | +var i=-1,o=t.length;for(r||(r=we),u||(u=[]);++i<o;){var f=t[i];0<n&&r(f)?1<n?En(f,n-1,r,e,u):s(u,f):e||(u[u.length]=f)}return u}function On(t,n){return t&&ro(t,n,Iu)}function Sn(t,n){return t&&eo(t,n,Iu)}function In(t,n){return f(n,function(n){return su(t[n])})}function Rn(t,n){n=ke(n,t)?[n]:Sr(n);for(var r=0,e=n.length;null!=t&&r<e;)t=t[Ue(n[r++])];return r&&r==e?t:F}function zn(t,n,r){return n=n(t),nf(t)?n:s(n,r(t))}function Wn(t,n){return t>n}function Bn(t,n){return null!=t&&ui.call(t,n)}function Ln(t,n){ | ||
28 | +return null!=t&&n in Ju(t)}function Un(t,n,r){for(var e=r?a:c,u=t[0].length,i=t.length,o=i,f=Zu(i),s=1/0,h=[];o--;){var p=t[o];o&&n&&(p=l(p,S(n))),s=Wi(p.length,s),f[o]=!r&&(n||120<=u&&120<=p.length)?new qt(o&&p):F}var p=t[0],_=-1,v=f[0];t:for(;++_<u&&h.length<s;){var g=p[_],d=n?n(g):g,g=r||0!==g?g:0;if(v?!R(v,d):!e(h,d,r)){for(o=i;--o;){var y=f[o];if(y?!R(y,d):!e(t[o],d,r))continue t}v&&v.push(d),h.push(g)}}return h}function Cn(t,n,r){var e={};return On(t,function(t,u,i){n(e,r(t),u,i)}),e}function Mn(t,n,e){ | ||
29 | +return ke(n,t)||(n=Sr(n),t=ze(t,n),n=Pe(n)),n=null==t?t:t[Ue(n)],null==n?F:r(n,t,e)}function Dn(t){return vu(t)&&"[object Arguments]"==fi.call(t)}function Tn(t){return vu(t)&&"[object ArrayBuffer]"==fi.call(t)}function $n(t){return vu(t)&&"[object Date]"==fi.call(t)}function Fn(t,n,r,e,u){if(t===n)n=true;else if(null==t||null==n||!_u(t)&&!vu(n))n=t!==t&&n!==n;else t:{var i=nf(t),o=nf(n),f="[object Array]",c="[object Array]";i||(f=Et(t),f="[object Arguments]"==f?"[object Object]":f),o||(c=Et(n),c="[object Arguments]"==c?"[object Object]":c); | ||
30 | +var a="[object Object]"==f,o="[object Object]"==c;if((c=f==c)&&ef(t)){if(!ef(n)){n=false;break t}i=true,a=false}if(c&&!a)u||(u=new Kt),n=i||af(t)?ce(t,n,Fn,r,e,u):ae(t,n,f,Fn,r,e,u);else{if(!(2&e)&&(i=a&&ui.call(t,"__wrapped__"),f=o&&ui.call(n,"__wrapped__"),i||f)){t=i?t.value():t,n=f?n.value():n,u||(u=new Kt),n=Fn(t,n,r,e,u);break t}if(c)n:if(u||(u=new Kt),i=2&e,f=Iu(t),o=f.length,c=Iu(n).length,o==c||i){for(a=o;a--;){var l=f[a];if(!(i?l in n:ui.call(n,l))){n=false;break n}}if((c=u.get(t))&&u.get(n))n=c==n;else{ | ||
31 | +c=true,u.set(t,n),u.set(n,t);for(var s=i;++a<o;){var l=f[a],h=t[l],p=n[l];if(r)var _=i?r(p,h,l,n,t,u):r(h,p,l,t,n,u);if(_===F?h!==p&&!Fn(h,p,r,e,u):!_){c=false;break}s||(s="constructor"==l)}c&&!s&&(r=t.constructor,e=n.constructor,r!=e&&"constructor"in t&&"constructor"in n&&!(typeof r=="function"&&r instanceof r&&typeof e=="function"&&e instanceof e)&&(c=false)),u.delete(t),u.delete(n),n=c}}else n=false;else n=false}}return n}function Nn(t){return vu(t)&&"[object Map]"==Et(t)}function Pn(t,n,r,e){var u=r.length,i=u,o=!e; | ||
32 | +if(null==t)return!i;for(t=Ju(t);u--;){var f=r[u];if(o&&f[2]?f[1]!==t[f[0]]:!(f[0]in t))return false}for(;++u<i;){var f=r[u],c=f[0],a=t[c],l=f[1];if(o&&f[2]){if(a===F&&!(c in t))return false}else{if(f=new Kt,e)var s=e(a,l,c,t,n,f);if(s===F?!Fn(l,a,e,3,f):!s)return false}}return true}function Zn(t){return!(!_u(t)||ri&&ri in t)&&(su(t)?ai:bt).test(Ce(t))}function qn(t){return _u(t)&&"[object RegExp]"==fi.call(t)}function Vn(t){return vu(t)&&"[object Set]"==Et(t)}function Kn(t){return vu(t)&&pu(t.length)&&!!Ut[fi.call(t)]; | ||
33 | +}function Gn(t){return typeof t=="function"?t:null==t?Mu:typeof t=="object"?nf(t)?Xn(t[0],t[1]):Qn(t):Fu(t)}function Jn(t){if(!Oe(t))return Ri(t);var n,r=[];for(n in Ju(t))ui.call(t,n)&&"constructor"!=n&&r.push(n);return r}function Yn(t,n){return t<n}function Hn(t,n){var r=-1,e=cu(t)?Zu(t.length):[];return to(t,function(t,u,i){e[++r]=n(t,u,i)}),e}function Qn(t){var n=ge(t);return 1==n.length&&n[0][2]?Se(n[0][0],n[0][1]):function(r){return r===t||Pn(r,t,n)}}function Xn(t,n){return ke(t)&&n===n&&!_u(n)?Se(Ue(t),n):function(r){ | ||
34 | +var e=Ou(r,t);return e===F&&e===n?Su(r,t):Fn(n,e,F,3)}}function tr(t,n,r,e,u){t!==n&&ro(n,function(i,o){if(_u(i)){u||(u=new Kt);var f=u,c=t[o],a=n[o],l=f.get(a);if(l)ln(t,o,l);else{var l=e?e(c,a,o+"",t,n,f):F,s=l===F;if(s){var h=nf(a),p=!h&&ef(a),_=!h&&!p&&af(a),l=a;h||p||_?nf(c)?l=c:au(c)?l=Cr(c):p?(s=false,l=Rr(a,true)):_?(s=false,l=Wr(a,true)):l=[]:du(a)||tf(a)?(l=c,tf(c)?l=ku(c):(!_u(c)||r&&su(c))&&(l=xe(a))):s=false}s&&(f.set(a,l),tr(l,a,r,e,f),f.delete(a)),ln(t,o,l)}}else f=e?e(t[o],i,o+"",t,n,u):F,f===F&&(f=i), | ||
35 | +ln(t,o,f)},Ru)}function nr(t,n){var r=t.length;if(r)return n+=0>n?r:0,me(n,r)?t[n]:F}function rr(t,n,r){var e=-1;return n=l(n.length?n:[Mu],S(_e())),t=Hn(t,function(t){return{a:l(n,function(n){return n(t)}),b:++e,c:t}}),A(t,function(t,n){var e;t:{e=-1;for(var u=t.a,i=n.a,o=u.length,f=r.length;++e<o;){var c=Br(u[e],i[e]);if(c){e=e>=f?c:c*("desc"==r[e]?-1:1);break t}}e=t.b-n.b}return e})}function er(t,n){return t=Ju(t),ur(t,n,function(n,r){return r in t})}function ur(t,n,r){for(var e=-1,u=n.length,i={};++e<u;){ | ||
36 | +var o=n[e],f=t[o];r(f,o)&&vn(i,o,f)}return i}function ir(t){return function(n){return Rn(n,t)}}function or(t,n,r,e){var u=e?y:d,i=-1,o=n.length,f=t;for(t===n&&(n=Cr(n)),r&&(f=l(t,S(r)));++i<o;)for(var c=0,a=n[i],a=r?r(a):a;-1<(c=u(f,a,c,e));)f!==t&&yi.call(f,c,1),yi.call(t,c,1);return t}function fr(t,n){for(var r=t?n.length:0,e=r-1;r--;){var u=n[r];if(r==e||u!==i){var i=u;if(me(u))yi.call(t,u,1);else if(ke(u,t))delete t[Ue(u)];else{var u=Sr(u),o=ze(t,u);null!=o&&delete o[Ue(Pe(u))]}}}}function cr(t,n){ | ||
37 | +return t+ki(Ui()*(n-t+1))}function ar(t,n){var r="";if(!t||1>n||9007199254740991<n)return r;do n%2&&(r+=t),(n=ki(n/2))&&(t+=t);while(n);return r}function lr(t,n){return _o(Re(t,n,Mu),t+"")}function sr(t){return on(Wu(t))}function hr(t,n){var r=Wu(t);return Le(r,dn(n,0,r.length))}function pr(t,n,r,e){if(!_u(t))return t;n=ke(n,t)?[n]:Sr(n);for(var u=-1,i=n.length,o=i-1,f=t;null!=f&&++u<i;){var c=Ue(n[u]),a=r;if(u!=o){var l=f[c],a=e?e(l,c,f):F;a===F&&(a=_u(l)?l:me(n[u+1])?[]:{})}sn(f,c,a),f=f[c]}return t; | ||
38 | +}function _r(t){return Le(Wu(t))}function vr(t,n,r){var e=-1,u=t.length;for(0>n&&(n=-n>u?0:u+n),r=r>u?u:r,0>r&&(r+=u),u=n>r?0:r-n>>>0,n>>>=0,r=Zu(u);++e<u;)r[e]=t[e+n];return r}function gr(t,n){var r;return to(t,function(t,e,u){return r=n(t,e,u),!r}),!!r}function dr(t,n,r){var e=0,u=t?t.length:e;if(typeof n=="number"&&n===n&&2147483647>=u){for(;e<u;){var i=e+u>>>1,o=t[i];null!==o&&!bu(o)&&(r?o<=n:o<n)?e=i+1:u=i}return u}return yr(t,n,Mu,r)}function yr(t,n,r,e){n=r(n);for(var u=0,i=t?t.length:0,o=n!==n,f=null===n,c=bu(n),a=n===F;u<i;){ | ||
39 | +var l=ki((u+i)/2),s=r(t[l]),h=s!==F,p=null===s,_=s===s,v=bu(s);(o?e||_:a?_&&(e||h):f?_&&h&&(e||!p):c?_&&h&&!p&&(e||!v):p||v?0:e?s<=n:s<n)?u=l+1:i=l}return Wi(i,4294967294)}function br(t,n){for(var r=-1,e=t.length,u=0,i=[];++r<e;){var o=t[r],f=n?n(o):o;if(!r||!fu(f,c)){var c=f;i[u++]=0===o?0:o}}return i}function xr(t){return typeof t=="number"?t:bu(t)?P:+t}function jr(t){if(typeof t=="string")return t;if(nf(t))return l(t,jr)+"";if(bu(t))return Qi?Qi.call(t):"";var n=t+"";return"0"==n&&1/t==-N?"-0":n; | ||
40 | +}function wr(t,n,r){var e=-1,u=c,i=t.length,o=true,f=[],l=f;if(r)o=false,u=a;else if(200<=i){if(u=n?null:fo(t))return M(u);o=false,u=R,l=new qt}else l=n?[]:f;t:for(;++e<i;){var s=t[e],h=n?n(s):s,s=r||0!==s?s:0;if(o&&h===h){for(var p=l.length;p--;)if(l[p]===h)continue t;n&&l.push(h),f.push(s)}else u(l,h,r)||(l!==f&&l.push(h),f.push(s))}return f}function mr(t,n,r,e){for(var u=t.length,i=e?u:-1;(e?i--:++i<u)&&n(t[i],i,t););return r?vr(t,e?0:i,e?i+1:u):vr(t,e?i+1:0,e?u:i)}function Ar(t,n){var r=t;return r instanceof Dt&&(r=r.value()), | ||
41 | +h(n,function(t,n){return n.func.apply(n.thisArg,s([t],n.args))},r)}function kr(t,n,r){for(var e=-1,u=t.length;++e<u;)var i=i?s(wn(i,t[e],n,r),wn(t[e],i,n,r)):t[e];return i&&i.length?wr(i,n,r):[]}function Er(t,n,r){for(var e=-1,u=t.length,i=n.length,o={};++e<u;)r(o,t[e],e<i?n[e]:F);return o}function Or(t){return au(t)?t:[]}function Sr(t){return nf(t)?t:vo(t)}function Ir(t,n,r){var e=t.length;return r=r===F?e:r,!n&&r>=e?t:vr(t,n,r)}function Rr(t,n){if(n)return t.slice();var r=t.length,r=pi?pi(r):new t.constructor(r); | ||
42 | +return t.copy(r),r}function zr(t){var n=new t.constructor(t.byteLength);return new hi(n).set(new hi(t)),n}function Wr(t,n){return new t.constructor(n?zr(t.buffer):t.buffer,t.byteOffset,t.length)}function Br(t,n){if(t!==n){var r=t!==F,e=null===t,u=t===t,i=bu(t),o=n!==F,f=null===n,c=n===n,a=bu(n);if(!f&&!a&&!i&&t>n||i&&o&&c&&!f&&!a||e&&o&&c||!r&&c||!u)return 1;if(!e&&!i&&!a&&t<n||a&&r&&u&&!e&&!i||f&&r&&u||!o&&u||!c)return-1}return 0}function Lr(t,n,r,e){var u=-1,i=t.length,o=r.length,f=-1,c=n.length,a=zi(i-o,0),l=Zu(c+a); | ||
43 | +for(e=!e;++f<c;)l[f]=n[f];for(;++u<o;)(e||u<i)&&(l[r[u]]=t[u]);for(;a--;)l[f++]=t[u++];return l}function Ur(t,n,r,e){var u=-1,i=t.length,o=-1,f=r.length,c=-1,a=n.length,l=zi(i-f,0),s=Zu(l+a);for(e=!e;++u<l;)s[u]=t[u];for(l=u;++c<a;)s[l+c]=n[c];for(;++o<f;)(e||u<i)&&(s[l+r[o]]=t[u++]);return s}function Cr(t,n){var r=-1,e=t.length;for(n||(n=Zu(e));++r<e;)n[r]=t[r];return n}function Mr(t,n,r,e){var u=!r;r||(r={});for(var i=-1,o=n.length;++i<o;){var f=n[i],c=e?e(r[f],t[f],f,r,t):F;c===F&&(c=t[f]),u?vn(r,f,c):sn(r,f,c); | ||
44 | +}return r}function Dr(t,n){return Mr(t,ao(t),n)}function Tr(t,n){return function(r,u){var i=nf(r)?e:pn,o=n?n():{};return i(r,t,_e(u,2),o)}}function $r(t){return lr(function(n,r){var e=-1,u=r.length,i=1<u?r[u-1]:F,o=2<u?r[2]:F,i=3<t.length&&typeof i=="function"?(u--,i):F;for(o&&Ae(r[0],r[1],o)&&(i=3>u?F:i,u=1),n=Ju(n);++e<u;)(o=r[e])&&t(n,o,e,i);return n})}function Fr(t,n){return function(r,e){if(null==r)return r;if(!cu(r))return t(r,e);for(var u=r.length,i=n?u:-1,o=Ju(r);(n?i--:++i<u)&&false!==e(o[i],i,o);); | ||
45 | +return r}}function Nr(t){return function(n,r,e){var u=-1,i=Ju(n);e=e(n);for(var o=e.length;o--;){var f=e[t?o:++u];if(false===r(i[f],f,i))break}return n}}function Pr(t,n,r){function e(){return(this&&this!==Pt&&this instanceof e?i:t).apply(u?r:this,arguments)}var u=1&n,i=Vr(t);return e}function Zr(t){return function(n){n=Eu(n);var r=Wt.test(n)?$(n):F,e=r?r[0]:n.charAt(0);return n=r?Ir(r,1).join(""):n.slice(1),e[t]()+n}}function qr(t){return function(n){return h(Uu(Lu(n).replace(St,"")),t,"")}}function Vr(t){ | ||
46 | +return function(){var n=arguments;switch(n.length){case 0:return new t;case 1:return new t(n[0]);case 2:return new t(n[0],n[1]);case 3:return new t(n[0],n[1],n[2]);case 4:return new t(n[0],n[1],n[2],n[3]);case 5:return new t(n[0],n[1],n[2],n[3],n[4]);case 6:return new t(n[0],n[1],n[2],n[3],n[4],n[5]);case 7:return new t(n[0],n[1],n[2],n[3],n[4],n[5],n[6])}var r=Xi(t.prototype),n=t.apply(r,n);return _u(n)?n:r}}function Kr(t,n,e){function u(){for(var o=arguments.length,f=Zu(o),c=o,a=pe(u);c--;)f[c]=arguments[c]; | ||
47 | +return c=3>o&&f[0]!==a&&f[o-1]!==a?[]:C(f,a),o-=c.length,o<e?ue(t,n,Yr,u.placeholder,F,f,c,F,F,e-o):r(this&&this!==Pt&&this instanceof u?i:t,this,f)}var i=Vr(t);return u}function Gr(t){return function(n,r,e){var u=Ju(n);if(!cu(n)){var i=_e(r,3);n=Iu(n),r=function(t){return i(u[t],t,u)}}return r=t(n,r,e),-1<r?u[i?n[r]:r]:F}}function Jr(t){return le(function(n){var r=n.length,e=r,u=Mt.prototype.thru;for(t&&n.reverse();e--;){var i=n[e];if(typeof i!="function")throw new Qu("Expected a function");if(u&&!o&&"wrapper"==he(i))var o=new Mt([],true); | ||
48 | +}for(e=o?e:r;++e<r;)var i=n[e],u=he(i),f="wrapper"==u?co(i):F,o=f&&Ee(f[0])&&424==f[1]&&!f[4].length&&1==f[9]?o[he(f[0])].apply(o,f[3]):1==i.length&&Ee(i)?o[u]():o.thru(i);return function(){var t=arguments,e=t[0];if(o&&1==t.length&&nf(e)&&200<=e.length)return o.plant(e).value();for(var u=0,t=r?n[u].apply(this,t):e;++u<r;)t=n[u].call(this,t);return t}})}function Yr(t,n,r,e,u,i,o,f,c,a){function l(){for(var d=arguments.length,y=Zu(d),b=d;b--;)y[b]=arguments[b];if(_){var x,j=pe(l),b=y.length;for(x=0;b--;)y[b]===j&&++x; | ||
49 | +}if(e&&(y=Lr(y,e,u,_)),i&&(y=Ur(y,i,o,_)),d-=x,_&&d<a)return j=C(y,j),ue(t,n,Yr,l.placeholder,r,y,j,f,c,a-d);if(j=h?r:this,b=p?j[t]:t,d=y.length,f){x=y.length;for(var w=Wi(f.length,x),m=Cr(y);w--;){var A=f[w];y[w]=me(A,x)?m[A]:F}}else v&&1<d&&y.reverse();return s&&c<d&&(y.length=c),this&&this!==Pt&&this instanceof l&&(b=g||Vr(b)),b.apply(j,y)}var s=128&n,h=1&n,p=2&n,_=24&n,v=512&n,g=p?F:Vr(t);return l}function Hr(t,n){return function(r,e){return Cn(r,t,n(e))}}function Qr(t,n){return function(r,e){ | ||
50 | +var u;if(r===F&&e===F)return n;if(r!==F&&(u=r),e!==F){if(u===F)return e;typeof r=="string"||typeof e=="string"?(r=jr(r),e=jr(e)):(r=xr(r),e=xr(e)),u=t(r,e)}return u}}function Xr(t){return le(function(n){return n=l(n,S(_e())),lr(function(e){var u=this;return t(n,function(t){return r(t,u,e)})})})}function te(t,n){n=n===F?" ":jr(n);var r=n.length;return 2>r?r?ar(n,t):n:(r=ar(n,Ai(t/T(n))),Wt.test(n)?Ir($(r),0,t).join(""):r.slice(0,t))}function ne(t,n,e,u){function i(){for(var n=-1,c=arguments.length,a=-1,l=u.length,s=Zu(l+c),h=this&&this!==Pt&&this instanceof i?f:t;++a<l;)s[a]=u[a]; | ||
51 | +for(;c--;)s[a++]=arguments[++n];return r(h,o?e:this,s)}var o=1&n,f=Vr(t);return i}function re(t){return function(n,r,e){e&&typeof e!="number"&&Ae(n,r,e)&&(r=e=F),n=ju(n),r===F?(r=n,n=0):r=ju(r),e=e===F?n<r?1:-1:ju(e);var u=-1;r=zi(Ai((r-n)/(e||1)),0);for(var i=Zu(r);r--;)i[t?r:++u]=n,n+=e;return i}}function ee(t){return function(n,r){return typeof n=="string"&&typeof r=="string"||(n=Au(n),r=Au(r)),t(n,r)}}function ue(t,n,r,e,u,i,o,f,c,a){var l=8&n,s=l?o:F;o=l?F:o;var h=l?i:F;return i=l?F:i,n=(n|(l?32:64))&~(l?64:32), | ||
52 | +4&n||(n&=-4),u=[t,n,u,h,s,i,o,f,c,a],r=r.apply(F,u),Ee(t)&&ho(r,u),r.placeholder=e,We(r,t,n)}function ie(t){var n=Gu[t];return function(t,r){if(t=Au(t),r=Wi(wu(r),292)){var e=(Eu(t)+"e").split("e"),e=n(e[0]+"e"+(+e[1]+r)),e=(Eu(e)+"e").split("e");return+(e[0]+"e"+(+e[1]-r))}return n(t)}}function oe(t){return function(n){var r=Et(n);return"[object Map]"==r?L(n):"[object Set]"==r?D(n):O(n,t(n))}}function fe(t,n,r,e,u,i,o,f){var c=2&n;if(!c&&typeof t!="function")throw new Qu("Expected a function");var a=e?e.length:0; | ||
53 | +if(a||(n&=-97,e=u=F),o=o===F?o:zi(wu(o),0),f=f===F?f:wu(f),a-=u?u.length:0,64&n){var l=e,s=u;e=u=F}var h=c?F:co(t);return i=[t,n,r,e,u,l,s,i,o,f],h&&(r=i[1],t=h[1],n=r|t,e=128==t&&8==r||128==t&&256==r&&i[7].length<=h[8]||384==t&&h[7].length<=h[8]&&8==r,131>n||e)&&(1&t&&(i[2]=h[2],n|=1&r?0:4),(r=h[3])&&(e=i[3],i[3]=e?Lr(e,r,h[4]):r,i[4]=e?C(i[3],"__lodash_placeholder__"):h[4]),(r=h[5])&&(e=i[5],i[5]=e?Ur(e,r,h[6]):r,i[6]=e?C(i[5],"__lodash_placeholder__"):h[6]),(r=h[7])&&(i[7]=r),128&t&&(i[8]=null==i[8]?h[8]:Wi(i[8],h[8])), | ||
54 | +null==i[9]&&(i[9]=h[9]),i[0]=h[0],i[1]=n),t=i[0],n=i[1],r=i[2],e=i[3],u=i[4],f=i[9]=null==i[9]?c?0:t.length:zi(i[9]-a,0),!f&&24&n&&(n&=-25),We((h?uo:ho)(n&&1!=n?8==n||16==n?Kr(t,n,f):32!=n&&33!=n||u.length?Yr.apply(F,i):ne(t,n,r,e):Pr(t,n,r),i),t,n)}function ce(t,n,r,e,u,i){var o=2&u,f=t.length,c=n.length;if(f!=c&&!(o&&c>f))return false;if((c=i.get(t))&&i.get(n))return c==n;var c=-1,a=true,l=1&u?new qt:F;for(i.set(t,n),i.set(n,t);++c<f;){var s=t[c],h=n[c];if(e)var p=o?e(h,s,c,n,t,i):e(s,h,c,t,n,i);if(p!==F){ | ||
55 | +if(p)continue;a=false;break}if(l){if(!_(n,function(t,n){if(!R(l,n)&&(s===t||r(s,t,e,u,i)))return l.push(n)})){a=false;break}}else if(s!==h&&!r(s,h,e,u,i)){a=false;break}}return i.delete(t),i.delete(n),a}function ae(t,n,r,e,u,i,o){switch(r){case"[object DataView]":if(t.byteLength!=n.byteLength||t.byteOffset!=n.byteOffset)break;t=t.buffer,n=n.buffer;case"[object ArrayBuffer]":if(t.byteLength!=n.byteLength||!e(new hi(t),new hi(n)))break;return true;case"[object Boolean]":case"[object Date]":case"[object Number]": | ||
56 | +return fu(+t,+n);case"[object Error]":return t.name==n.name&&t.message==n.message;case"[object RegExp]":case"[object String]":return t==n+"";case"[object Map]":var f=L;case"[object Set]":if(f||(f=M),t.size!=n.size&&!(2&i))break;return(r=o.get(t))?r==n:(i|=1,o.set(t,n),n=ce(f(t),f(n),e,u,i,o),o.delete(t),n);case"[object Symbol]":if(Hi)return Hi.call(t)==Hi.call(n)}return false}function le(t){return _o(Re(t,F,Fe),t+"")}function se(t){return zn(t,Iu,ao)}function he(t){for(var n=t.name+"",r=Zi[n],e=ui.call(Zi,n)?r.length:0;e--;){ | ||
57 | +var u=r[e],i=u.func;if(null==i||i==t)return u.name}return n}function pe(t){return(ui.call(Ot,"placeholder")?Ot:t).placeholder}function _e(){var t=Ot.iteratee||Du,t=t===Du?Gn:t;return arguments.length?t(arguments[0],arguments[1]):t}function ve(t,n){var r=t.__data__,e=typeof n;return("string"==e||"number"==e||"symbol"==e||"boolean"==e?"__proto__"!==n:null===n)?r[typeof n=="string"?"string":"hash"]:r.map}function ge(t){for(var n=Iu(t),r=n.length;r--;){var e=n[r],u=t[e];n[r]=[e,u,u===u&&!_u(u)]}return n; | ||
58 | +}function de(t,n){var r=null==t?F:t[n];return Zn(r)?r:F}function ye(t,n,r){n=ke(n,t)?[n]:Sr(n);for(var e=-1,u=n.length,i=false;++e<u;){var o=Ue(n[e]);if(!(i=null!=t&&r(t,o)))break;t=t[o]}return i||++e!=u?i:(u=t?t.length:0,!!u&&pu(u)&&me(o,u)&&(nf(t)||tf(t)))}function be(t){var n=t.length,r=t.constructor(n);return n&&"string"==typeof t[0]&&ui.call(t,"index")&&(r.index=t.index,r.input=t.input),r}function xe(t){return typeof t.constructor!="function"||Oe(t)?{}:Xi(_i(t))}function je(r,e,u,i){var o=r.constructor; | ||
59 | +switch(e){case"[object ArrayBuffer]":return zr(r);case"[object Boolean]":case"[object Date]":return new o(+r);case"[object DataView]":return e=i?zr(r.buffer):r.buffer,new r.constructor(e,r.byteOffset,r.byteLength);case"[object Float32Array]":case"[object Float64Array]":case"[object Int8Array]":case"[object Int16Array]":case"[object Int32Array]":case"[object Uint8Array]":case"[object Uint8ClampedArray]":case"[object Uint16Array]":case"[object Uint32Array]":return Wr(r,i);case"[object Map]":return e=i?u(L(r),true):L(r), | ||
60 | +h(e,t,new r.constructor);case"[object Number]":case"[object String]":return new o(r);case"[object RegExp]":return e=new r.constructor(r.source,gt.exec(r)),e.lastIndex=r.lastIndex,e;case"[object Set]":return e=i?u(M(r),true):M(r),h(e,n,new r.constructor);case"[object Symbol]":return Hi?Ju(Hi.call(r)):{}}}function we(t){return nf(t)||tf(t)||!!(bi&&t&&t[bi])}function me(t,n){return n=null==n?9007199254740991:n,!!n&&(typeof t=="number"||jt.test(t))&&-1<t&&0==t%1&&t<n}function Ae(t,n,r){if(!_u(r))return false; | ||
61 | +var e=typeof n;return!!("number"==e?cu(r)&&me(n,r.length):"string"==e&&n in r)&&fu(r[n],t)}function ke(t,n){if(nf(t))return false;var r=typeof t;return!("number"!=r&&"symbol"!=r&&"boolean"!=r&&null!=t&&!bu(t))||(rt.test(t)||!nt.test(t)||null!=n&&t in Ju(n))}function Ee(t){var n=he(t),r=Ot[n];return typeof r=="function"&&n in Dt.prototype&&(t===r||(n=co(r),!!n&&t===n[0]))}function Oe(t){var n=t&&t.constructor;return t===(typeof n=="function"&&n.prototype||ti)}function Se(t,n){return function(r){return null!=r&&(r[t]===n&&(n!==F||t in Ju(r))); | ||
62 | +}}function Ie(t,n,r,e,u,i){return _u(t)&&_u(n)&&(i.set(n,t),tr(t,n,F,Ie,i),i.delete(n)),t}function Re(t,n,e){return n=zi(n===F?t.length-1:n,0),function(){for(var u=arguments,i=-1,o=zi(u.length-n,0),f=Zu(o);++i<o;)f[i]=u[n+i];for(i=-1,o=Zu(n+1);++i<n;)o[i]=u[i];return o[n]=e(f),r(t,this,o)}}function ze(t,n){return 1==n.length?t:Rn(t,vr(n,0,-1))}function We(t,n,r){var e=n+"";n=_o;var u,i=Me;return u=(u=e.match(st))?u[1].split(ht):[],r=i(u,r),(i=r.length)&&(u=i-1,r[u]=(1<i?"& ":"")+r[u],r=r.join(2<i?", ":" "), | ||
63 | +e=e.replace(lt,"{\n/* [wrapped with "+r+"] */\n")),n(t,e)}function Be(t){var n=0,r=0;return function(){var e=Bi(),u=16-(e-r);if(r=e,0<u){if(500<=++n)return arguments[0]}else n=0;return t.apply(F,arguments)}}function Le(t,n){var r=-1,e=t.length,u=e-1;for(n=n===F?e:n;++r<n;){var e=cr(r,u),i=t[e];t[e]=t[r],t[r]=i}return t.length=n,t}function Ue(t){if(typeof t=="string"||bu(t))return t;var n=t+"";return"0"==n&&1/t==-N?"-0":n}function Ce(t){if(null!=t){try{return ei.call(t)}catch(t){}return t+""}return""; | ||
64 | +}function Me(t,n){return u(Z,function(r){var e="_."+r[0];n&r[1]&&!c(t,e)&&t.push(e)}),t.sort()}function De(t){if(t instanceof Dt)return t.clone();var n=new Mt(t.__wrapped__,t.__chain__);return n.__actions__=Cr(t.__actions__),n.__index__=t.__index__,n.__values__=t.__values__,n}function Te(t,n,r){var e=t?t.length:0;return e?(r=null==r?0:wu(r),0>r&&(r=zi(e+r,0)),g(t,_e(n,3),r)):-1}function $e(t,n,r){var e=t?t.length:0;if(!e)return-1;var u=e-1;return r!==F&&(u=wu(r),u=0>r?zi(e+u,0):Wi(u,e-1)),g(t,_e(n,3),u,true); | ||
65 | +}function Fe(t){return t&&t.length?En(t,1):[]}function Ne(t){return t&&t.length?t[0]:F}function Pe(t){var n=t?t.length:0;return n?t[n-1]:F}function Ze(t,n){return t&&t.length&&n&&n.length?or(t,n):t}function qe(t){return t?Ci.call(t):t}function Ve(t){if(!t||!t.length)return[];var n=0;return t=f(t,function(t){if(au(t))return n=zi(t.length,n),true}),E(n,function(n){return l(t,j(n))})}function Ke(t,n){if(!t||!t.length)return[];var e=Ve(t);return null==n?e:l(e,function(t){return r(n,F,t)})}function Ge(t){ | ||
66 | +return t=Ot(t),t.__chain__=true,t}function Je(t,n){return n(t)}function Ye(){return this}function He(t,n){return(nf(t)?u:to)(t,_e(n,3))}function Qe(t,n){return(nf(t)?i:no)(t,_e(n,3))}function Xe(t,n){return(nf(t)?l:Hn)(t,_e(n,3))}function tu(t,n,r){return n=r?F:n,n=t&&null==n?t.length:n,fe(t,128,F,F,F,F,n)}function nu(t,n){var r;if(typeof n!="function")throw new Qu("Expected a function");return t=wu(t),function(){return 0<--t&&(r=n.apply(this,arguments)),1>=t&&(n=F),r}}function ru(t,n,r){return n=r?F:n, | ||
67 | +t=fe(t,8,F,F,F,F,F,n),t.placeholder=ru.placeholder,t}function eu(t,n,r){return n=r?F:n,t=fe(t,16,F,F,F,F,F,n),t.placeholder=eu.placeholder,t}function uu(t,n,r){function e(n){var r=c,e=a;return c=a=F,_=n,s=t.apply(e,r)}function u(t){var r=t-p;return t-=_,p===F||r>=n||0>r||g&&t>=l}function i(){var t=Po();if(u(t))return o(t);var r,e=po;r=t-_,t=n-(t-p),r=g?Wi(t,l-r):t,h=e(i,r)}function o(t){return h=F,d&&c?e(t):(c=a=F,s)}function f(){var t=Po(),r=u(t);if(c=arguments,a=this,p=t,r){if(h===F)return _=t=p, | ||
68 | +h=po(i,n),v?e(t):s;if(g)return h=po(i,n),e(p)}return h===F&&(h=po(i,n)),s}var c,a,l,s,h,p,_=0,v=false,g=false,d=true;if(typeof t!="function")throw new Qu("Expected a function");return n=Au(n)||0,_u(r)&&(v=!!r.leading,l=(g="maxWait"in r)?zi(Au(r.maxWait)||0,n):l,d="trailing"in r?!!r.trailing:d),f.cancel=function(){h!==F&&oo(h),_=0,c=p=a=h=F},f.flush=function(){return h===F?s:o(Po())},f}function iu(t,n){function r(){var e=arguments,u=n?n.apply(this,e):e[0],i=r.cache;return i.has(u)?i.get(u):(e=t.apply(this,e), | ||
69 | +r.cache=i.set(u,e)||i,e)}if(typeof t!="function"||n&&typeof n!="function")throw new Qu("Expected a function");return r.cache=new(iu.Cache||Zt),r}function ou(t){if(typeof t!="function")throw new Qu("Expected a function");return function(){var n=arguments;switch(n.length){case 0:return!t.call(this);case 1:return!t.call(this,n[0]);case 2:return!t.call(this,n[0],n[1]);case 3:return!t.call(this,n[0],n[1],n[2])}return!t.apply(this,n)}}function fu(t,n){return t===n||t!==t&&n!==n}function cu(t){return null!=t&&pu(t.length)&&!su(t); | ||
70 | +}function au(t){return vu(t)&&cu(t)}function lu(t){return!!vu(t)&&("[object Error]"==fi.call(t)||typeof t.message=="string"&&typeof t.name=="string")}function su(t){return t=_u(t)?fi.call(t):"","[object Function]"==t||"[object GeneratorFunction]"==t||"[object Proxy]"==t}function hu(t){return typeof t=="number"&&t==wu(t)}function pu(t){return typeof t=="number"&&-1<t&&0==t%1&&9007199254740991>=t}function _u(t){var n=typeof t;return null!=t&&("object"==n||"function"==n)}function vu(t){return null!=t&&typeof t=="object"; | ||
71 | +}function gu(t){return typeof t=="number"||vu(t)&&"[object Number]"==fi.call(t)}function du(t){return!(!vu(t)||"[object Object]"!=fi.call(t))&&(t=_i(t),null===t||(t=ui.call(t,"constructor")&&t.constructor,typeof t=="function"&&t instanceof t&&ei.call(t)==oi))}function yu(t){return typeof t=="string"||!nf(t)&&vu(t)&&"[object String]"==fi.call(t)}function bu(t){return typeof t=="symbol"||vu(t)&&"[object Symbol]"==fi.call(t)}function xu(t){if(!t)return[];if(cu(t))return yu(t)?$(t):Cr(t);if(vi&&t[vi]){t=t[vi](); | ||
72 | +for(var n,r=[];!(n=t.next()).done;)r.push(n.value);return r}return n=Et(t),("[object Map]"==n?L:"[object Set]"==n?M:Wu)(t)}function ju(t){return t?(t=Au(t),t===N||t===-N?1.7976931348623157e308*(0>t?-1:1):t===t?t:0):0===t?t:0}function wu(t){t=ju(t);var n=t%1;return t===t?n?t-n:t:0}function mu(t){return t?dn(wu(t),0,4294967295):0}function Au(t){if(typeof t=="number")return t;if(bu(t))return P;if(_u(t)&&(t=typeof t.valueOf=="function"?t.valueOf():t,t=_u(t)?t+"":t),typeof t!="string")return 0===t?t:+t; | ||
73 | +t=t.replace(ft,"");var n=yt.test(t);return n||xt.test(t)?$t(t.slice(2),n?2:8):dt.test(t)?P:+t}function ku(t){return Mr(t,Ru(t))}function Eu(t){return null==t?"":jr(t)}function Ou(t,n,r){return t=null==t?F:Rn(t,n),t===F?r:t}function Su(t,n){return null!=t&&ye(t,n,Ln)}function Iu(t){return cu(t)?tn(t):Jn(t)}function Ru(t){if(cu(t))t=tn(t,true);else if(_u(t)){var n,r=Oe(t),e=[];for(n in t)("constructor"!=n||!r&&ui.call(t,n))&&e.push(n);t=e}else{if(n=[],null!=t)for(r in Ju(t))n.push(r);t=n}return t}function zu(t,n){ | ||
74 | +return null==t?{}:ur(t,zn(t,Ru,lo),_e(n))}function Wu(t){return t?I(t,Iu(t)):[]}function Bu(t){return Uf(Eu(t).toLowerCase())}function Lu(t){return(t=Eu(t))&&t.replace(wt,nn).replace(It,"")}function Uu(t,n,r){return t=Eu(t),n=r?F:n,n===F?Bt.test(t)?t.match(zt)||[]:t.match(pt)||[]:t.match(n)||[]}function Cu(t){return function(){return t}}function Mu(t){return t}function Du(t){return Gn(typeof t=="function"?t:yn(t,true))}function Tu(t,n,r){var e=Iu(n),i=In(n,e);null!=r||_u(n)&&(i.length||!e.length)||(r=n, | ||
75 | +n=t,t=this,i=In(n,Iu(n)));var o=!(_u(r)&&"chain"in r&&!r.chain),f=su(t);return u(i,function(r){var e=n[r];t[r]=e,f&&(t.prototype[r]=function(){var n=this.__chain__;if(o||n){var r=t(this.__wrapped__);return(r.__actions__=Cr(this.__actions__)).push({func:e,args:arguments,thisArg:t}),r.__chain__=n,r}return e.apply(t,s([this.value()],arguments))})}),t}function $u(){}function Fu(t){return ke(t)?j(Ue(t)):ir(t)}function Nu(){return[]}function Pu(){return false}kt=kt?un.defaults(Pt.Object(),kt,un.pick(Pt,Lt)):Pt; | ||
76 | +var Zu=kt.Array,qu=kt.Date,Vu=kt.Error,Ku=kt.Function,Gu=kt.Math,Ju=kt.Object,Yu=kt.RegExp,Hu=kt.String,Qu=kt.TypeError,Xu=Zu.prototype,ti=Ju.prototype,ni=kt["__core-js_shared__"],ri=function(){var t=/[^.]+$/.exec(ni&&ni.keys&&ni.keys.IE_PROTO||"");return t?"Symbol(src)_1."+t:""}(),ei=Ku.prototype.toString,ui=ti.hasOwnProperty,ii=0,oi=ei.call(Ju),fi=ti.toString,ci=Pt._,ai=Yu("^"+ei.call(ui).replace(it,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),li=Vt?kt.Buffer:F,si=kt.Symbol,hi=kt.Uint8Array,pi=li?li.f:F,_i=U(Ju.getPrototypeOf,Ju),vi=si?si.iterator:F,gi=Ju.create,di=ti.propertyIsEnumerable,yi=Xu.splice,bi=si?si.isConcatSpreadable:F,xi=function(){ | ||
77 | +try{var t=de(Ju,"defineProperty");return t({},"",{}),t}catch(t){}}(),ji=kt.clearTimeout!==Pt.clearTimeout&&kt.clearTimeout,wi=qu&&qu.now!==Pt.Date.now&&qu.now,mi=kt.setTimeout!==Pt.setTimeout&&kt.setTimeout,Ai=Gu.ceil,ki=Gu.floor,Ei=Ju.getOwnPropertySymbols,Oi=li?li.isBuffer:F,Si=kt.isFinite,Ii=Xu.join,Ri=U(Ju.keys,Ju),zi=Gu.max,Wi=Gu.min,Bi=qu.now,Li=kt.parseInt,Ui=Gu.random,Ci=Xu.reverse,Mi=de(kt,"DataView"),Di=de(kt,"Map"),Ti=de(kt,"Promise"),$i=de(kt,"Set"),Fi=de(kt,"WeakMap"),Ni=de(Ju,"create"),Pi=Fi&&new Fi,Zi={},qi=Ce(Mi),Vi=Ce(Di),Ki=Ce(Ti),Gi=Ce($i),Ji=Ce(Fi),Yi=si?si.prototype:F,Hi=Yi?Yi.valueOf:F,Qi=Yi?Yi.toString:F,Xi=function(){ | ||
78 | +function t(){}return function(n){return _u(n)?gi?gi(n):(t.prototype=n,n=new t,t.prototype=F,n):{}}}();Ot.templateSettings={escape:Q,evaluate:X,interpolate:tt,variable:"",imports:{_:Ot}},Ot.prototype=Rt.prototype,Ot.prototype.constructor=Ot,Mt.prototype=Xi(Rt.prototype),Mt.prototype.constructor=Mt,Dt.prototype=Xi(Rt.prototype),Dt.prototype.constructor=Dt,Ft.prototype.clear=function(){this.__data__=Ni?Ni(null):{},this.size=0},Ft.prototype.delete=function(t){return t=this.has(t)&&delete this.__data__[t], | ||
79 | +this.size-=t?1:0,t},Ft.prototype.get=function(t){var n=this.__data__;return Ni?(t=n[t],"__lodash_hash_undefined__"===t?F:t):ui.call(n,t)?n[t]:F},Ft.prototype.has=function(t){var n=this.__data__;return Ni?n[t]!==F:ui.call(n,t)},Ft.prototype.set=function(t,n){var r=this.__data__;return this.size+=this.has(t)?0:1,r[t]=Ni&&n===F?"__lodash_hash_undefined__":n,this},Nt.prototype.clear=function(){this.__data__=[],this.size=0},Nt.prototype.delete=function(t){var n=this.__data__;return t=hn(n,t),!(0>t)&&(t==n.length-1?n.pop():yi.call(n,t,1), | ||
80 | +--this.size,true)},Nt.prototype.get=function(t){var n=this.__data__;return t=hn(n,t),0>t?F:n[t][1]},Nt.prototype.has=function(t){return-1<hn(this.__data__,t)},Nt.prototype.set=function(t,n){var r=this.__data__,e=hn(r,t);return 0>e?(++this.size,r.push([t,n])):r[e][1]=n,this},Zt.prototype.clear=function(){this.size=0,this.__data__={hash:new Ft,map:new(Di||Nt),string:new Ft}},Zt.prototype.delete=function(t){return t=ve(this,t).delete(t),this.size-=t?1:0,t},Zt.prototype.get=function(t){return ve(this,t).get(t); | ||
81 | +},Zt.prototype.has=function(t){return ve(this,t).has(t)},Zt.prototype.set=function(t,n){var r=ve(this,t),e=r.size;return r.set(t,n),this.size+=r.size==e?0:1,this},qt.prototype.add=qt.prototype.push=function(t){return this.__data__.set(t,"__lodash_hash_undefined__"),this},qt.prototype.has=function(t){return this.__data__.has(t)},Kt.prototype.clear=function(){this.__data__=new Nt,this.size=0},Kt.prototype.delete=function(t){var n=this.__data__;return t=n.delete(t),this.size=n.size,t},Kt.prototype.get=function(t){ | ||
82 | +return this.__data__.get(t)},Kt.prototype.has=function(t){return this.__data__.has(t)},Kt.prototype.set=function(t,n){var r=this.__data__;if(r instanceof Nt){var e=r.__data__;if(!Di||199>e.length)return e.push([t,n]),this.size=++r.size,this;r=this.__data__=new Zt(e)}return r.set(t,n),this.size=r.size,this};var to=Fr(On),no=Fr(Sn,true),ro=Nr(),eo=Nr(true),uo=Pi?function(t,n){return Pi.set(t,n),t}:Mu,io=xi?function(t,n){return xi(t,"toString",{configurable:true,enumerable:false,value:Cu(n),writable:true})}:Mu,oo=ji||function(t){ | ||
83 | +return Pt.clearTimeout(t)},fo=$i&&1/M(new $i([,-0]))[1]==N?function(t){return new $i(t)}:$u,co=Pi?function(t){return Pi.get(t)}:$u,ao=Ei?U(Ei,Ju):Nu,lo=Ei?function(t){for(var n=[];t;)s(n,ao(t)),t=_i(t);return n}:Nu;(Mi&&"[object DataView]"!=Et(new Mi(new ArrayBuffer(1)))||Di&&"[object Map]"!=Et(new Di)||Ti&&"[object Promise]"!=Et(Ti.resolve())||$i&&"[object Set]"!=Et(new $i)||Fi&&"[object WeakMap]"!=Et(new Fi))&&(Et=function(t){var n=fi.call(t);if(t=(t="[object Object]"==n?t.constructor:F)?Ce(t):F)switch(t){ | ||
84 | +case qi:return"[object DataView]";case Vi:return"[object Map]";case Ki:return"[object Promise]";case Gi:return"[object Set]";case Ji:return"[object WeakMap]"}return n});var so=ni?su:Pu,ho=Be(uo),po=mi||function(t,n){return Pt.setTimeout(t,n)},_o=Be(io),vo=function(t){t=iu(t,function(t){return 500===n.size&&n.clear(),t});var n=t.cache;return t}(function(t){t=Eu(t);var n=[];return et.test(t)&&n.push(""),t.replace(ut,function(t,r,e,u){n.push(e?u.replace(_t,"$1"):r||t)}),n}),go=lr(function(t,n){return au(t)?wn(t,En(n,1,au,true)):[]; | ||
85 | +}),yo=lr(function(t,n){var r=Pe(n);return au(r)&&(r=F),au(t)?wn(t,En(n,1,au,true),_e(r,2)):[]}),bo=lr(function(t,n){var r=Pe(n);return au(r)&&(r=F),au(t)?wn(t,En(n,1,au,true),F,r):[]}),xo=lr(function(t){var n=l(t,Or);return n.length&&n[0]===t[0]?Un(n):[]}),jo=lr(function(t){var n=Pe(t),r=l(t,Or);return n===Pe(r)?n=F:r.pop(),r.length&&r[0]===t[0]?Un(r,_e(n,2)):[]}),wo=lr(function(t){var n=Pe(t),r=l(t,Or);return n===Pe(r)?n=F:r.pop(),r.length&&r[0]===t[0]?Un(r,F,n):[]}),mo=lr(Ze),Ao=le(function(t,n){var r=t?t.length:0,e=gn(t,n); | ||
86 | +return fr(t,l(n,function(t){return me(t,r)?+t:t}).sort(Br)),e}),ko=lr(function(t){return wr(En(t,1,au,true))}),Eo=lr(function(t){var n=Pe(t);return au(n)&&(n=F),wr(En(t,1,au,true),_e(n,2))}),Oo=lr(function(t){var n=Pe(t);return au(n)&&(n=F),wr(En(t,1,au,true),F,n)}),So=lr(function(t,n){return au(t)?wn(t,n):[]}),Io=lr(function(t){return kr(f(t,au))}),Ro=lr(function(t){var n=Pe(t);return au(n)&&(n=F),kr(f(t,au),_e(n,2))}),zo=lr(function(t){var n=Pe(t);return au(n)&&(n=F),kr(f(t,au),F,n)}),Wo=lr(Ve),Bo=lr(function(t){ | ||
87 | +var n=t.length,n=1<n?t[n-1]:F,n=typeof n=="function"?(t.pop(),n):F;return Ke(t,n)}),Lo=le(function(t){function n(n){return gn(n,t)}var r=t.length,e=r?t[0]:0,u=this.__wrapped__;return!(1<r||this.__actions__.length)&&u instanceof Dt&&me(e)?(u=u.slice(e,+e+(r?1:0)),u.__actions__.push({func:Je,args:[n],thisArg:F}),new Mt(u,this.__chain__).thru(function(t){return r&&!t.length&&t.push(F),t})):this.thru(n)}),Uo=Tr(function(t,n,r){ui.call(t,r)?++t[r]:vn(t,r,1)}),Co=Gr(Te),Mo=Gr($e),Do=Tr(function(t,n,r){ | ||
88 | +ui.call(t,r)?t[r].push(n):vn(t,r,[n])}),To=lr(function(t,n,e){var u=-1,i=typeof n=="function",o=ke(n),f=cu(t)?Zu(t.length):[];return to(t,function(t){var c=i?n:o&&null!=t?t[n]:F;f[++u]=c?r(c,t,e):Mn(t,n,e)}),f}),$o=Tr(function(t,n,r){vn(t,r,n)}),Fo=Tr(function(t,n,r){t[r?0:1].push(n)},function(){return[[],[]]}),No=lr(function(t,n){if(null==t)return[];var r=n.length;return 1<r&&Ae(t,n[0],n[1])?n=[]:2<r&&Ae(n[0],n[1],n[2])&&(n=[n[0]]),rr(t,En(n,1),[])}),Po=wi||function(){return Pt.Date.now()},Zo=lr(function(t,n,r){ | ||
89 | +var e=1;if(r.length)var u=C(r,pe(Zo)),e=32|e;return fe(t,e,n,r,u)}),qo=lr(function(t,n,r){var e=3;if(r.length)var u=C(r,pe(qo)),e=32|e;return fe(n,e,t,r,u)}),Vo=lr(function(t,n){return jn(t,1,n)}),Ko=lr(function(t,n,r){return jn(t,Au(n)||0,r)});iu.Cache=Zt;var Go=lr(function(t,n){n=1==n.length&&nf(n[0])?l(n[0],S(_e())):l(En(n,1),S(_e()));var e=n.length;return lr(function(u){for(var i=-1,o=Wi(u.length,e);++i<o;)u[i]=n[i].call(this,u[i]);return r(t,this,u)})}),Jo=lr(function(t,n){return fe(t,32,F,n,C(n,pe(Jo))); | ||
90 | +}),Yo=lr(function(t,n){return fe(t,64,F,n,C(n,pe(Yo)))}),Ho=le(function(t,n){return fe(t,256,F,F,F,n)}),Qo=ee(Wn),Xo=ee(function(t,n){return t>=n}),tf=Dn(function(){return arguments}())?Dn:function(t){return vu(t)&&ui.call(t,"callee")&&!di.call(t,"callee")},nf=Zu.isArray,rf=Gt?S(Gt):Tn,ef=Oi||Pu,uf=Jt?S(Jt):$n,of=Yt?S(Yt):Nn,ff=Ht?S(Ht):qn,cf=Qt?S(Qt):Vn,af=Xt?S(Xt):Kn,lf=ee(Yn),sf=ee(function(t,n){return t<=n}),hf=$r(function(t,n){if(Oe(n)||cu(n))Mr(n,Iu(n),t);else for(var r in n)ui.call(n,r)&&sn(t,r,n[r]); | ||
91 | +}),pf=$r(function(t,n){Mr(n,Ru(n),t)}),_f=$r(function(t,n,r,e){Mr(n,Ru(n),t,e)}),vf=$r(function(t,n,r,e){Mr(n,Iu(n),t,e)}),gf=le(gn),df=lr(function(t){return t.push(F,an),r(_f,F,t)}),yf=lr(function(t){return t.push(F,Ie),r(mf,F,t)}),bf=Hr(function(t,n,r){t[n]=r},Cu(Mu)),xf=Hr(function(t,n,r){ui.call(t,n)?t[n].push(r):t[n]=[r]},_e),jf=lr(Mn),wf=$r(function(t,n,r){tr(t,n,r)}),mf=$r(function(t,n,r,e){tr(t,n,r,e)}),Af=le(function(t,n){return null==t?{}:(n=l(n,Ue),er(t,wn(zn(t,Ru,lo),n)))}),kf=le(function(t,n){ | ||
92 | +return null==t?{}:er(t,l(n,Ue))}),Ef=oe(Iu),Of=oe(Ru),Sf=qr(function(t,n,r){return n=n.toLowerCase(),t+(r?Bu(n):n)}),If=qr(function(t,n,r){return t+(r?"-":"")+n.toLowerCase()}),Rf=qr(function(t,n,r){return t+(r?" ":"")+n.toLowerCase()}),zf=Zr("toLowerCase"),Wf=qr(function(t,n,r){return t+(r?"_":"")+n.toLowerCase()}),Bf=qr(function(t,n,r){return t+(r?" ":"")+Uf(n)}),Lf=qr(function(t,n,r){return t+(r?" ":"")+n.toUpperCase()}),Uf=Zr("toUpperCase"),Cf=lr(function(t,n){try{return r(t,F,n)}catch(t){return lu(t)?t:new Vu(t); | ||
93 | +}}),Mf=le(function(t,n){return u(n,function(n){n=Ue(n),vn(t,n,Zo(t[n],t))}),t}),Df=Jr(),Tf=Jr(true),$f=lr(function(t,n){return function(r){return Mn(r,t,n)}}),Ff=lr(function(t,n){return function(r){return Mn(t,r,n)}}),Nf=Xr(l),Pf=Xr(o),Zf=Xr(_),qf=re(),Vf=re(true),Kf=Qr(function(t,n){return t+n},0),Gf=ie("ceil"),Jf=Qr(function(t,n){return t/n},1),Yf=ie("floor"),Hf=Qr(function(t,n){return t*n},1),Qf=ie("round"),Xf=Qr(function(t,n){return t-n},0);return Ot.after=function(t,n){if(typeof n!="function")throw new Qu("Expected a function"); | ||
94 | +return t=wu(t),function(){if(1>--t)return n.apply(this,arguments)}},Ot.ary=tu,Ot.assign=hf,Ot.assignIn=pf,Ot.assignInWith=_f,Ot.assignWith=vf,Ot.at=gf,Ot.before=nu,Ot.bind=Zo,Ot.bindAll=Mf,Ot.bindKey=qo,Ot.castArray=function(){if(!arguments.length)return[];var t=arguments[0];return nf(t)?t:[t]},Ot.chain=Ge,Ot.chunk=function(t,n,r){if(n=(r?Ae(t,n,r):n===F)?1:zi(wu(n),0),r=t?t.length:0,!r||1>n)return[];for(var e=0,u=0,i=Zu(Ai(r/n));e<r;)i[u++]=vr(t,e,e+=n);return i},Ot.compact=function(t){for(var n=-1,r=t?t.length:0,e=0,u=[];++n<r;){ | ||
95 | +var i=t[n];i&&(u[e++]=i)}return u},Ot.concat=function(){var t=arguments.length;if(!t)return[];for(var n=Zu(t-1),r=arguments[0];t--;)n[t-1]=arguments[t];return s(nf(r)?Cr(r):[r],En(n,1))},Ot.cond=function(t){var n=t?t.length:0,e=_e();return t=n?l(t,function(t){if("function"!=typeof t[1])throw new Qu("Expected a function");return[e(t[0]),t[1]]}):[],lr(function(e){for(var u=-1;++u<n;){var i=t[u];if(r(i[0],this,e))return r(i[1],this,e)}})},Ot.conforms=function(t){return bn(yn(t,true))},Ot.constant=Cu,Ot.countBy=Uo, | ||
96 | +Ot.create=function(t,n){var r=Xi(t);return n?_n(r,n):r},Ot.curry=ru,Ot.curryRight=eu,Ot.debounce=uu,Ot.defaults=df,Ot.defaultsDeep=yf,Ot.defer=Vo,Ot.delay=Ko,Ot.difference=go,Ot.differenceBy=yo,Ot.differenceWith=bo,Ot.drop=function(t,n,r){var e=t?t.length:0;return e?(n=r||n===F?1:wu(n),vr(t,0>n?0:n,e)):[]},Ot.dropRight=function(t,n,r){var e=t?t.length:0;return e?(n=r||n===F?1:wu(n),n=e-n,vr(t,0,0>n?0:n)):[]},Ot.dropRightWhile=function(t,n){return t&&t.length?mr(t,_e(n,3),true,true):[]},Ot.dropWhile=function(t,n){ | ||
97 | +return t&&t.length?mr(t,_e(n,3),true):[]},Ot.fill=function(t,n,r,e){var u=t?t.length:0;if(!u)return[];for(r&&typeof r!="number"&&Ae(t,n,r)&&(r=0,e=u),u=t.length,r=wu(r),0>r&&(r=-r>u?0:u+r),e=e===F||e>u?u:wu(e),0>e&&(e+=u),e=r>e?0:mu(e);r<e;)t[r++]=n;return t},Ot.filter=function(t,n){return(nf(t)?f:kn)(t,_e(n,3))},Ot.flatMap=function(t,n){return En(Xe(t,n),1)},Ot.flatMapDeep=function(t,n){return En(Xe(t,n),N)},Ot.flatMapDepth=function(t,n,r){return r=r===F?1:wu(r),En(Xe(t,n),r)},Ot.flatten=Fe,Ot.flattenDeep=function(t){ | ||
98 | +return t&&t.length?En(t,N):[]},Ot.flattenDepth=function(t,n){return t&&t.length?(n=n===F?1:wu(n),En(t,n)):[]},Ot.flip=function(t){return fe(t,512)},Ot.flow=Df,Ot.flowRight=Tf,Ot.fromPairs=function(t){for(var n=-1,r=t?t.length:0,e={};++n<r;){var u=t[n];e[u[0]]=u[1]}return e},Ot.functions=function(t){return null==t?[]:In(t,Iu(t))},Ot.functionsIn=function(t){return null==t?[]:In(t,Ru(t))},Ot.groupBy=Do,Ot.initial=function(t){return t&&t.length?vr(t,0,-1):[]},Ot.intersection=xo,Ot.intersectionBy=jo,Ot.intersectionWith=wo, | ||
99 | +Ot.invert=bf,Ot.invertBy=xf,Ot.invokeMap=To,Ot.iteratee=Du,Ot.keyBy=$o,Ot.keys=Iu,Ot.keysIn=Ru,Ot.map=Xe,Ot.mapKeys=function(t,n){var r={};return n=_e(n,3),On(t,function(t,e,u){vn(r,n(t,e,u),t)}),r},Ot.mapValues=function(t,n){var r={};return n=_e(n,3),On(t,function(t,e,u){vn(r,e,n(t,e,u))}),r},Ot.matches=function(t){return Qn(yn(t,true))},Ot.matchesProperty=function(t,n){return Xn(t,yn(n,true))},Ot.memoize=iu,Ot.merge=wf,Ot.mergeWith=mf,Ot.method=$f,Ot.methodOf=Ff,Ot.mixin=Tu,Ot.negate=ou,Ot.nthArg=function(t){ | ||
100 | +return t=wu(t),lr(function(n){return nr(n,t)})},Ot.omit=Af,Ot.omitBy=function(t,n){return zu(t,ou(_e(n)))},Ot.once=function(t){return nu(2,t)},Ot.orderBy=function(t,n,r,e){return null==t?[]:(nf(n)||(n=null==n?[]:[n]),r=e?F:r,nf(r)||(r=null==r?[]:[r]),rr(t,n,r))},Ot.over=Nf,Ot.overArgs=Go,Ot.overEvery=Pf,Ot.overSome=Zf,Ot.partial=Jo,Ot.partialRight=Yo,Ot.partition=Fo,Ot.pick=kf,Ot.pickBy=zu,Ot.property=Fu,Ot.propertyOf=function(t){return function(n){return null==t?F:Rn(t,n)}},Ot.pull=mo,Ot.pullAll=Ze, | ||
101 | +Ot.pullAllBy=function(t,n,r){return t&&t.length&&n&&n.length?or(t,n,_e(r,2)):t},Ot.pullAllWith=function(t,n,r){return t&&t.length&&n&&n.length?or(t,n,F,r):t},Ot.pullAt=Ao,Ot.range=qf,Ot.rangeRight=Vf,Ot.rearg=Ho,Ot.reject=function(t,n){return(nf(t)?f:kn)(t,ou(_e(n,3)))},Ot.remove=function(t,n){var r=[];if(!t||!t.length)return r;var e=-1,u=[],i=t.length;for(n=_e(n,3);++e<i;){var o=t[e];n(o,e,t)&&(r.push(o),u.push(e))}return fr(t,u),r},Ot.rest=function(t,n){if(typeof t!="function")throw new Qu("Expected a function"); | ||
102 | +return n=n===F?n:wu(n),lr(t,n)},Ot.reverse=qe,Ot.sampleSize=function(t,n,r){return n=(r?Ae(t,n,r):n===F)?1:wu(n),(nf(t)?fn:hr)(t,n)},Ot.set=function(t,n,r){return null==t?t:pr(t,n,r)},Ot.setWith=function(t,n,r,e){return e=typeof e=="function"?e:F,null==t?t:pr(t,n,r,e)},Ot.shuffle=function(t){return(nf(t)?cn:_r)(t)},Ot.slice=function(t,n,r){var e=t?t.length:0;return e?(r&&typeof r!="number"&&Ae(t,n,r)?(n=0,r=e):(n=null==n?0:wu(n),r=r===F?e:wu(r)),vr(t,n,r)):[]},Ot.sortBy=No,Ot.sortedUniq=function(t){ | ||
103 | +return t&&t.length?br(t):[]},Ot.sortedUniqBy=function(t,n){return t&&t.length?br(t,_e(n,2)):[]},Ot.split=function(t,n,r){return r&&typeof r!="number"&&Ae(t,n,r)&&(n=r=F),r=r===F?4294967295:r>>>0,r?(t=Eu(t))&&(typeof n=="string"||null!=n&&!ff(n))&&(n=jr(n),!n&&Wt.test(t))?Ir($(t),0,r):t.split(n,r):[]},Ot.spread=function(t,n){if(typeof t!="function")throw new Qu("Expected a function");return n=n===F?0:zi(wu(n),0),lr(function(e){var u=e[n];return e=Ir(e,0,n),u&&s(e,u),r(t,this,e)})},Ot.tail=function(t){ | ||
104 | +var n=t?t.length:0;return n?vr(t,1,n):[]},Ot.take=function(t,n,r){return t&&t.length?(n=r||n===F?1:wu(n),vr(t,0,0>n?0:n)):[]},Ot.takeRight=function(t,n,r){var e=t?t.length:0;return e?(n=r||n===F?1:wu(n),n=e-n,vr(t,0>n?0:n,e)):[]},Ot.takeRightWhile=function(t,n){return t&&t.length?mr(t,_e(n,3),false,true):[]},Ot.takeWhile=function(t,n){return t&&t.length?mr(t,_e(n,3)):[]},Ot.tap=function(t,n){return n(t),t},Ot.throttle=function(t,n,r){var e=true,u=true;if(typeof t!="function")throw new Qu("Expected a function"); | ||
105 | +return _u(r)&&(e="leading"in r?!!r.leading:e,u="trailing"in r?!!r.trailing:u),uu(t,n,{leading:e,maxWait:n,trailing:u})},Ot.thru=Je,Ot.toArray=xu,Ot.toPairs=Ef,Ot.toPairsIn=Of,Ot.toPath=function(t){return nf(t)?l(t,Ue):bu(t)?[t]:Cr(vo(t))},Ot.toPlainObject=ku,Ot.transform=function(t,n,r){var e=nf(t),i=e||ef(t)||af(t);if(n=_e(n,4),null==r){var o=t&&t.constructor;r=i?e?new o:[]:_u(t)&&su(o)?Xi(_i(t)):{}}return(i?u:On)(t,function(t,e,u){return n(r,t,e,u)}),r},Ot.unary=function(t){return tu(t,1)},Ot.union=ko, | ||
106 | +Ot.unionBy=Eo,Ot.unionWith=Oo,Ot.uniq=function(t){return t&&t.length?wr(t):[]},Ot.uniqBy=function(t,n){return t&&t.length?wr(t,_e(n,2)):[]},Ot.uniqWith=function(t,n){return t&&t.length?wr(t,F,n):[]},Ot.unset=function(t,n){var r;if(null==t)r=true;else{r=t;var e=n,e=ke(e,r)?[e]:Sr(e);r=ze(r,e),e=Ue(Pe(e)),r=!(null!=r&&ui.call(r,e))||delete r[e]}return r},Ot.unzip=Ve,Ot.unzipWith=Ke,Ot.update=function(t,n,r){return null==t?t:pr(t,n,(typeof r=="function"?r:Mu)(Rn(t,n)),void 0)},Ot.updateWith=function(t,n,r,e){ | ||
107 | +return e=typeof e=="function"?e:F,null!=t&&(t=pr(t,n,(typeof r=="function"?r:Mu)(Rn(t,n)),e)),t},Ot.values=Wu,Ot.valuesIn=function(t){return null==t?[]:I(t,Ru(t))},Ot.without=So,Ot.words=Uu,Ot.wrap=function(t,n){return n=null==n?Mu:n,Jo(n,t)},Ot.xor=Io,Ot.xorBy=Ro,Ot.xorWith=zo,Ot.zip=Wo,Ot.zipObject=function(t,n){return Er(t||[],n||[],sn)},Ot.zipObjectDeep=function(t,n){return Er(t||[],n||[],pr)},Ot.zipWith=Bo,Ot.entries=Ef,Ot.entriesIn=Of,Ot.extend=pf,Ot.extendWith=_f,Tu(Ot,Ot),Ot.add=Kf,Ot.attempt=Cf, | ||
108 | +Ot.camelCase=Sf,Ot.capitalize=Bu,Ot.ceil=Gf,Ot.clamp=function(t,n,r){return r===F&&(r=n,n=F),r!==F&&(r=Au(r),r=r===r?r:0),n!==F&&(n=Au(n),n=n===n?n:0),dn(Au(t),n,r)},Ot.clone=function(t){return yn(t,false,true)},Ot.cloneDeep=function(t){return yn(t,true,true)},Ot.cloneDeepWith=function(t,n){return yn(t,true,true,n)},Ot.cloneWith=function(t,n){return yn(t,false,true,n)},Ot.conformsTo=function(t,n){return null==n||xn(t,n,Iu(n))},Ot.deburr=Lu,Ot.defaultTo=function(t,n){return null==t||t!==t?n:t},Ot.divide=Jf,Ot.endsWith=function(t,n,r){ | ||
109 | +t=Eu(t),n=jr(n);var e=t.length,e=r=r===F?e:dn(wu(r),0,e);return r-=n.length,0<=r&&t.slice(r,e)==n},Ot.eq=fu,Ot.escape=function(t){return(t=Eu(t))&&H.test(t)?t.replace(J,rn):t},Ot.escapeRegExp=function(t){return(t=Eu(t))&&ot.test(t)?t.replace(it,"\\$&"):t},Ot.every=function(t,n,r){var e=nf(t)?o:mn;return r&&Ae(t,n,r)&&(n=F),e(t,_e(n,3))},Ot.find=Co,Ot.findIndex=Te,Ot.findKey=function(t,n){return v(t,_e(n,3),On)},Ot.findLast=Mo,Ot.findLastIndex=$e,Ot.findLastKey=function(t,n){return v(t,_e(n,3),Sn); | ||
110 | +},Ot.floor=Yf,Ot.forEach=He,Ot.forEachRight=Qe,Ot.forIn=function(t,n){return null==t?t:ro(t,_e(n,3),Ru)},Ot.forInRight=function(t,n){return null==t?t:eo(t,_e(n,3),Ru)},Ot.forOwn=function(t,n){return t&&On(t,_e(n,3))},Ot.forOwnRight=function(t,n){return t&&Sn(t,_e(n,3))},Ot.get=Ou,Ot.gt=Qo,Ot.gte=Xo,Ot.has=function(t,n){return null!=t&&ye(t,n,Bn)},Ot.hasIn=Su,Ot.head=Ne,Ot.identity=Mu,Ot.includes=function(t,n,r,e){return t=cu(t)?t:Wu(t),r=r&&!e?wu(r):0,e=t.length,0>r&&(r=zi(e+r,0)),yu(t)?r<=e&&-1<t.indexOf(n,r):!!e&&-1<d(t,n,r); | ||
111 | +},Ot.indexOf=function(t,n,r){var e=t?t.length:0;return e?(r=null==r?0:wu(r),0>r&&(r=zi(e+r,0)),d(t,n,r)):-1},Ot.inRange=function(t,n,r){return n=ju(n),r===F?(r=n,n=0):r=ju(r),t=Au(t),t>=Wi(n,r)&&t<zi(n,r)},Ot.invoke=jf,Ot.isArguments=tf,Ot.isArray=nf,Ot.isArrayBuffer=rf,Ot.isArrayLike=cu,Ot.isArrayLikeObject=au,Ot.isBoolean=function(t){return true===t||false===t||vu(t)&&"[object Boolean]"==fi.call(t)},Ot.isBuffer=ef,Ot.isDate=uf,Ot.isElement=function(t){return null!=t&&1===t.nodeType&&vu(t)&&!du(t)},Ot.isEmpty=function(t){ | ||
112 | +if(cu(t)&&(nf(t)||typeof t=="string"||typeof t.splice=="function"||ef(t)||af(t)||tf(t)))return!t.length;var n=Et(t);if("[object Map]"==n||"[object Set]"==n)return!t.size;if(Oe(t))return!Jn(t).length;for(var r in t)if(ui.call(t,r))return false;return true},Ot.isEqual=function(t,n){return Fn(t,n)},Ot.isEqualWith=function(t,n,r){var e=(r=typeof r=="function"?r:F)?r(t,n):F;return e===F?Fn(t,n,r):!!e},Ot.isError=lu,Ot.isFinite=function(t){return typeof t=="number"&&Si(t)},Ot.isFunction=su,Ot.isInteger=hu,Ot.isLength=pu, | ||
113 | +Ot.isMap=of,Ot.isMatch=function(t,n){return t===n||Pn(t,n,ge(n))},Ot.isMatchWith=function(t,n,r){return r=typeof r=="function"?r:F,Pn(t,n,ge(n),r)},Ot.isNaN=function(t){return gu(t)&&t!=+t},Ot.isNative=function(t){if(so(t))throw new Vu("Unsupported core-js use. Try https://github.com/es-shims.");return Zn(t)},Ot.isNil=function(t){return null==t},Ot.isNull=function(t){return null===t},Ot.isNumber=gu,Ot.isObject=_u,Ot.isObjectLike=vu,Ot.isPlainObject=du,Ot.isRegExp=ff,Ot.isSafeInteger=function(t){return hu(t)&&-9007199254740991<=t&&9007199254740991>=t; | ||
114 | +},Ot.isSet=cf,Ot.isString=yu,Ot.isSymbol=bu,Ot.isTypedArray=af,Ot.isUndefined=function(t){return t===F},Ot.isWeakMap=function(t){return vu(t)&&"[object WeakMap]"==Et(t)},Ot.isWeakSet=function(t){return vu(t)&&"[object WeakSet]"==fi.call(t)},Ot.join=function(t,n){return t?Ii.call(t,n):""},Ot.kebabCase=If,Ot.last=Pe,Ot.lastIndexOf=function(t,n,r){var e=t?t.length:0;if(!e)return-1;var u=e;if(r!==F&&(u=wu(r),u=0>u?zi(e+u,0):Wi(u,e-1)),n===n){for(r=u+1;r--&&t[r]!==n;);t=r}else t=g(t,b,u,true);return t}, | ||
115 | +Ot.lowerCase=Rf,Ot.lowerFirst=zf,Ot.lt=lf,Ot.lte=sf,Ot.max=function(t){return t&&t.length?An(t,Mu,Wn):F},Ot.maxBy=function(t,n){return t&&t.length?An(t,_e(n,2),Wn):F},Ot.mean=function(t){return x(t,Mu)},Ot.meanBy=function(t,n){return x(t,_e(n,2))},Ot.min=function(t){return t&&t.length?An(t,Mu,Yn):F},Ot.minBy=function(t,n){return t&&t.length?An(t,_e(n,2),Yn):F},Ot.stubArray=Nu,Ot.stubFalse=Pu,Ot.stubObject=function(){return{}},Ot.stubString=function(){return""},Ot.stubTrue=function(){return true},Ot.multiply=Hf, | ||
116 | +Ot.nth=function(t,n){return t&&t.length?nr(t,wu(n)):F},Ot.noConflict=function(){return Pt._===this&&(Pt._=ci),this},Ot.noop=$u,Ot.now=Po,Ot.pad=function(t,n,r){t=Eu(t);var e=(n=wu(n))?T(t):0;return!n||e>=n?t:(n=(n-e)/2,te(ki(n),r)+t+te(Ai(n),r))},Ot.padEnd=function(t,n,r){t=Eu(t);var e=(n=wu(n))?T(t):0;return n&&e<n?t+te(n-e,r):t},Ot.padStart=function(t,n,r){t=Eu(t);var e=(n=wu(n))?T(t):0;return n&&e<n?te(n-e,r)+t:t},Ot.parseInt=function(t,n,r){return r||null==n?n=0:n&&(n=+n),Li(Eu(t).replace(ct,""),n||0); | ||
117 | +},Ot.random=function(t,n,r){if(r&&typeof r!="boolean"&&Ae(t,n,r)&&(n=r=F),r===F&&(typeof n=="boolean"?(r=n,n=F):typeof t=="boolean"&&(r=t,t=F)),t===F&&n===F?(t=0,n=1):(t=ju(t),n===F?(n=t,t=0):n=ju(n)),t>n){var e=t;t=n,n=e}return r||t%1||n%1?(r=Ui(),Wi(t+r*(n-t+Tt("1e-"+((r+"").length-1))),n)):cr(t,n)},Ot.reduce=function(t,n,r){var e=nf(t)?h:m,u=3>arguments.length;return e(t,_e(n,4),r,u,to)},Ot.reduceRight=function(t,n,r){var e=nf(t)?p:m,u=3>arguments.length;return e(t,_e(n,4),r,u,no)},Ot.repeat=function(t,n,r){ | ||
118 | +return n=(r?Ae(t,n,r):n===F)?1:wu(n),ar(Eu(t),n)},Ot.replace=function(){var t=arguments,n=Eu(t[0]);return 3>t.length?n:n.replace(t[1],t[2])},Ot.result=function(t,n,r){n=ke(n,t)?[n]:Sr(n);var e=-1,u=n.length;for(u||(t=F,u=1);++e<u;){var i=null==t?F:t[Ue(n[e])];i===F&&(e=u,i=r),t=su(i)?i.call(t):i}return t},Ot.round=Qf,Ot.runInContext=w,Ot.sample=function(t){return(nf(t)?on:sr)(t)},Ot.size=function(t){if(null==t)return 0;if(cu(t))return yu(t)?T(t):t.length;var n=Et(t);return"[object Map]"==n||"[object Set]"==n?t.size:Jn(t).length; | ||
119 | +},Ot.snakeCase=Wf,Ot.some=function(t,n,r){var e=nf(t)?_:gr;return r&&Ae(t,n,r)&&(n=F),e(t,_e(n,3))},Ot.sortedIndex=function(t,n){return dr(t,n)},Ot.sortedIndexBy=function(t,n,r){return yr(t,n,_e(r,2))},Ot.sortedIndexOf=function(t,n){var r=t?t.length:0;if(r){var e=dr(t,n);if(e<r&&fu(t[e],n))return e}return-1},Ot.sortedLastIndex=function(t,n){return dr(t,n,true)},Ot.sortedLastIndexBy=function(t,n,r){return yr(t,n,_e(r,2),true)},Ot.sortedLastIndexOf=function(t,n){if(t&&t.length){var r=dr(t,n,true)-1;if(fu(t[r],n))return r; | ||
120 | +}return-1},Ot.startCase=Bf,Ot.startsWith=function(t,n,r){return t=Eu(t),r=dn(wu(r),0,t.length),n=jr(n),t.slice(r,r+n.length)==n},Ot.subtract=Xf,Ot.sum=function(t){return t&&t.length?k(t,Mu):0},Ot.sumBy=function(t,n){return t&&t.length?k(t,_e(n,2)):0},Ot.template=function(t,n,r){var e=Ot.templateSettings;r&&Ae(t,n,r)&&(n=F),t=Eu(t),n=_f({},n,e,an),r=_f({},n.imports,e.imports,an);var u,i,o=Iu(r),f=I(r,o),c=0;r=n.interpolate||mt;var a="__p+='";r=Yu((n.escape||mt).source+"|"+r.source+"|"+(r===tt?vt:mt).source+"|"+(n.evaluate||mt).source+"|$","g"); | ||
121 | +var l="sourceURL"in n?"//# sourceURL="+n.sourceURL+"\n":"";if(t.replace(r,function(n,r,e,o,f,l){return e||(e=o),a+=t.slice(c,l).replace(At,B),r&&(u=true,a+="'+__e("+r+")+'"),f&&(i=true,a+="';"+f+";\n__p+='"),e&&(a+="'+((__t=("+e+"))==null?'':__t)+'"),c=l+n.length,n}),a+="';",(n=n.variable)||(a="with(obj){"+a+"}"),a=(i?a.replace(q,""):a).replace(V,"$1").replace(K,"$1;"),a="function("+(n||"obj")+"){"+(n?"":"obj||(obj={});")+"var __t,__p=''"+(u?",__e=_.escape":"")+(i?",__j=Array.prototype.join;function print(){__p+=__j.call(arguments,'')}":";")+a+"return __p}", | ||
122 | +n=Cf(function(){return Ku(o,l+"return "+a).apply(F,f)}),n.source=a,lu(n))throw n;return n},Ot.times=function(t,n){if(t=wu(t),1>t||9007199254740991<t)return[];var r=4294967295,e=Wi(t,4294967295);for(n=_e(n),t-=4294967295,e=E(e,n);++r<t;)n(r);return e},Ot.toFinite=ju,Ot.toInteger=wu,Ot.toLength=mu,Ot.toLower=function(t){return Eu(t).toLowerCase()},Ot.toNumber=Au,Ot.toSafeInteger=function(t){return dn(wu(t),-9007199254740991,9007199254740991)},Ot.toString=Eu,Ot.toUpper=function(t){return Eu(t).toUpperCase(); | ||
123 | +},Ot.trim=function(t,n,r){return(t=Eu(t))&&(r||n===F)?t.replace(ft,""):t&&(n=jr(n))?(t=$(t),r=$(n),n=z(t,r),r=W(t,r)+1,Ir(t,n,r).join("")):t},Ot.trimEnd=function(t,n,r){return(t=Eu(t))&&(r||n===F)?t.replace(at,""):t&&(n=jr(n))?(t=$(t),n=W(t,$(n))+1,Ir(t,0,n).join("")):t},Ot.trimStart=function(t,n,r){return(t=Eu(t))&&(r||n===F)?t.replace(ct,""):t&&(n=jr(n))?(t=$(t),n=z(t,$(n)),Ir(t,n).join("")):t},Ot.truncate=function(t,n){var r=30,e="...";if(_u(n))var u="separator"in n?n.separator:u,r="length"in n?wu(n.length):r,e="omission"in n?jr(n.omission):e; | ||
124 | +t=Eu(t);var i=t.length;if(Wt.test(t))var o=$(t),i=o.length;if(r>=i)return t;if(i=r-T(e),1>i)return e;if(r=o?Ir(o,0,i).join(""):t.slice(0,i),u===F)return r+e;if(o&&(i+=r.length-i),ff(u)){if(t.slice(i).search(u)){var f=r;for(u.global||(u=Yu(u.source,Eu(gt.exec(u))+"g")),u.lastIndex=0;o=u.exec(f);)var c=o.index;r=r.slice(0,c===F?i:c)}}else t.indexOf(jr(u),i)!=i&&(u=r.lastIndexOf(u),-1<u&&(r=r.slice(0,u)));return r+e},Ot.unescape=function(t){return(t=Eu(t))&&Y.test(t)?t.replace(G,en):t},Ot.uniqueId=function(t){ | ||
125 | +var n=++ii;return Eu(t)+n},Ot.upperCase=Lf,Ot.upperFirst=Uf,Ot.each=He,Ot.eachRight=Qe,Ot.first=Ne,Tu(Ot,function(){var t={};return On(Ot,function(n,r){ui.call(Ot.prototype,r)||(t[r]=n)}),t}(),{chain:false}),Ot.VERSION="4.16.4",u("bind bindKey curry curryRight partial partialRight".split(" "),function(t){Ot[t].placeholder=Ot}),u(["drop","take"],function(t,n){Dt.prototype[t]=function(r){var e=this.__filtered__;if(e&&!n)return new Dt(this);r=r===F?1:zi(wu(r),0);var u=this.clone();return e?u.__takeCount__=Wi(r,u.__takeCount__):u.__views__.push({ | ||
126 | +size:Wi(r,4294967295),type:t+(0>u.__dir__?"Right":"")}),u},Dt.prototype[t+"Right"]=function(n){return this.reverse()[t](n).reverse()}}),u(["filter","map","takeWhile"],function(t,n){var r=n+1,e=1==r||3==r;Dt.prototype[t]=function(t){var n=this.clone();return n.__iteratees__.push({iteratee:_e(t,3),type:r}),n.__filtered__=n.__filtered__||e,n}}),u(["head","last"],function(t,n){var r="take"+(n?"Right":"");Dt.prototype[t]=function(){return this[r](1).value()[0]}}),u(["initial","tail"],function(t,n){var r="drop"+(n?"":"Right"); | ||
127 | +Dt.prototype[t]=function(){return this.__filtered__?new Dt(this):this[r](1)}}),Dt.prototype.compact=function(){return this.filter(Mu)},Dt.prototype.find=function(t){return this.filter(t).head()},Dt.prototype.findLast=function(t){return this.reverse().find(t)},Dt.prototype.invokeMap=lr(function(t,n){return typeof t=="function"?new Dt(this):this.map(function(r){return Mn(r,t,n)})}),Dt.prototype.reject=function(t){return this.filter(ou(_e(t)))},Dt.prototype.slice=function(t,n){t=wu(t);var r=this;return r.__filtered__&&(0<t||0>n)?new Dt(r):(0>t?r=r.takeRight(-t):t&&(r=r.drop(t)), | ||
128 | +n!==F&&(n=wu(n),r=0>n?r.dropRight(-n):r.take(n-t)),r)},Dt.prototype.takeRightWhile=function(t){return this.reverse().takeWhile(t).reverse()},Dt.prototype.toArray=function(){return this.take(4294967295)},On(Dt.prototype,function(t,n){var r=/^(?:filter|find|map|reject)|While$/.test(n),e=/^(?:head|last)$/.test(n),u=Ot[e?"take"+("last"==n?"Right":""):n],i=e||/^find/.test(n);u&&(Ot.prototype[n]=function(){function n(t){return t=u.apply(Ot,s([t],f)),e&&h?t[0]:t}var o=this.__wrapped__,f=e?[1]:arguments,c=o instanceof Dt,a=f[0],l=c||nf(o); | ||
129 | +l&&r&&typeof a=="function"&&1!=a.length&&(c=l=false);var h=this.__chain__,p=!!this.__actions__.length,a=i&&!h,c=c&&!p;return!i&&l?(o=c?o:new Dt(this),o=t.apply(o,f),o.__actions__.push({func:Je,args:[n],thisArg:F}),new Mt(o,h)):a&&c?t.apply(this,f):(o=this.thru(n),a?e?o.value()[0]:o.value():o)})}),u("pop push shift sort splice unshift".split(" "),function(t){var n=Xu[t],r=/^(?:push|sort|unshift)$/.test(t)?"tap":"thru",e=/^(?:pop|shift)$/.test(t);Ot.prototype[t]=function(){var t=arguments;if(e&&!this.__chain__){ | ||
130 | +var u=this.value();return n.apply(nf(u)?u:[],t)}return this[r](function(r){return n.apply(nf(r)?r:[],t)})}}),On(Dt.prototype,function(t,n){var r=Ot[n];if(r){var e=r.name+"";(Zi[e]||(Zi[e]=[])).push({name:n,func:r})}}),Zi[Yr(F,2).name]=[{name:"wrapper",func:F}],Dt.prototype.clone=function(){var t=new Dt(this.__wrapped__);return t.__actions__=Cr(this.__actions__),t.__dir__=this.__dir__,t.__filtered__=this.__filtered__,t.__iteratees__=Cr(this.__iteratees__),t.__takeCount__=this.__takeCount__,t.__views__=Cr(this.__views__), | ||
131 | +t},Dt.prototype.reverse=function(){if(this.__filtered__){var t=new Dt(this);t.__dir__=-1,t.__filtered__=true}else t=this.clone(),t.__dir__*=-1;return t},Dt.prototype.value=function(){var t,n=this.__wrapped__.value(),r=this.__dir__,e=nf(n),u=0>r,i=e?n.length:0;t=i;for(var o=this.__views__,f=0,c=-1,a=o.length;++c<a;){var l=o[c],s=l.size;switch(l.type){case"drop":f+=s;break;case"dropRight":t-=s;break;case"take":t=Wi(t,f+s);break;case"takeRight":f=zi(f,t-s)}}if(t={start:f,end:t},o=t.start,f=t.end,t=f-o, | ||
132 | +u=u?f:o-1,o=this.__iteratees__,f=o.length,c=0,a=Wi(t,this.__takeCount__),!e||200>i||i==t&&a==t)return Ar(n,this.__actions__);e=[];t:for(;t--&&c<a;){for(u+=r,i=-1,l=n[u];++i<f;){var h=o[i],s=h.type,h=(0,h.iteratee)(l);if(2==s)l=h;else if(!h){if(1==s)continue t;break t}}e[c++]=l}return e},Ot.prototype.at=Lo,Ot.prototype.chain=function(){return Ge(this)},Ot.prototype.commit=function(){return new Mt(this.value(),this.__chain__)},Ot.prototype.next=function(){this.__values__===F&&(this.__values__=xu(this.value())); | ||
133 | +var t=this.__index__>=this.__values__.length;return{done:t,value:t?F:this.__values__[this.__index__++]}},Ot.prototype.plant=function(t){for(var n,r=this;r instanceof Rt;){var e=De(r);e.__index__=0,e.__values__=F,n?u.__wrapped__=e:n=e;var u=e,r=r.__wrapped__}return u.__wrapped__=t,n},Ot.prototype.reverse=function(){var t=this.__wrapped__;return t instanceof Dt?(this.__actions__.length&&(t=new Dt(this)),t=t.reverse(),t.__actions__.push({func:Je,args:[qe],thisArg:F}),new Mt(t,this.__chain__)):this.thru(qe); | ||
134 | +},Ot.prototype.toJSON=Ot.prototype.valueOf=Ot.prototype.value=function(){return Ar(this.__wrapped__,this.__actions__)},Ot.prototype.first=Ot.prototype.head,vi&&(Ot.prototype[vi]=Ye),Ot}();typeof define=="function"&&typeof define.amd=="object"&&define.amd?(Pt._=un, define(function(){return un})):qt?((qt.exports=un)._=un,Zt._=un):Pt._=un}).call(this); | ||
... | \ No newline at end of file | ... | \ No newline at end of file |
-
Please register or login to post a comment