rails_mini_profiler 0.5.0 → 0.6.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 7e87dd3ae71d8ef0ab8021c31b037db8b290521782577dad5a7143cbbbd2f8f1
4
- data.tar.gz: 1f7060bde727f2dbcdd7f4b6269d2436744cfb625484ed7bf43b5e4659743e6f
3
+ metadata.gz: 3ee7ad78091b3a10151ce83c08c255e9ccc78c16112a74a89c939876c52146ed
4
+ data.tar.gz: 33c09a36420c374b1b40a8cdbaec6a9a5a0ef5822dddc9bb2e6a47902c0ddce3
5
5
  SHA512:
6
- metadata.gz: 4e90925e2addb71264c09084a9b4244553b466f40e87f96902e60e9301b3befe3ed898a6578e6dd4a3c5c51cb18974fecda9036e6e5d82f27f3bac5bbce9e3aa
7
- data.tar.gz: ed964b334db077211701b956c43f9f0e778bcd260e1097f1eaface96ffacbefe5c6e6bef01e6326f06db318da925a1a0d3a72790bf6c267e0e7d1309844ff95b
6
+ metadata.gz: a40ccbdbfd8a40b8b9eba3ba9a1f29436bd25f645640112ad0cda3426a7b4c3c4b8fe174569c304c3a8dbe3cc1c1987d5b6bee4b2c4a52309cd0e273879f437e
7
+ data.tar.gz: 7f7527d2d8fd2e898951a36ecfb0e413cf1264b1dc495a637e4cd1a802ab690df754ae3c39d5d626e37c931120430c0f8a58a78262c5672b0f27edf7c2262ae3
data/README.md CHANGED
@@ -158,11 +158,13 @@ end
158
158
 
159
159
  Rails Mini Profiler allows you to configure various UI features.
160
160
 
161
- | Name | Default | Description |
162
- |------------------|--------------|-------------------------------------------------------------------------------------------------|
163
- | `badge_enabled` | `true` | Should the hedgehog 🦔 badge be injected into pages? |
164
- | `badge_position` | `'top-left'` | Where to display the badge. Options are `'top-left', 'top-right', 'bottom-left, 'bottom-right'` |
165
- | `page_size` | `25` | The page size for lists shown in the UI. |
161
+ | Name | Default | Description |
162
+ |---------------------|--------------|-------------------------------------------------------------------------------------------------|
163
+ | `badge_enabled` | `true` | Should the hedgehog 🦔 badge be injected into pages? |
164
+ | `badge_position` | `'top-left'` | Where to display the badge. Options are `'top-left', 'top-right', 'bottom-left, 'bottom-right'` |
165
+ | `page_size` | `25` | The page size for lists shown in the UI. |
166
+ | `webpacker_enabled` | `true` | Use Webpacker if available? Disable to fall back to the asset pipeline.
167
+
166
168
 
167
169
  ### Users
168
170
 
@@ -12,7 +12,7 @@ module RailsMiniProfiler
12
12
  end
13
13
 
14
14
  def inline_svg(path, options = {})
15
- if defined?(Webpacker::Engine)
15
+ if defined?(Webpacker::Engine) && RailsMiniProfiler.configuration.ui.webpacker_enabled
16
16
  path = "media/images/#{path}"
17
17
  inline_svg_pack_tag(path, options)
18
18
  else
@@ -0,0 +1,6 @@
1
+ <svg xmlns="http://www.w3.org/2000/svg"
2
+ viewBox="0 0 488.3 488.3" style="enable-background:new 0 0 488.3 488.3" xml:space="preserve">
3
+ <path fill="currentColor"
4
+ d="M314.25 85.4h-227c-21.3 0-38.6 17.3-38.6 38.6v325.7c0 21.3 17.3 38.6 38.6 38.6h227c21.3 0 38.6-17.3 38.6-38.6V124c-.1-21.3-17.4-38.6-38.6-38.6zm11.5 364.2c0 6.4-5.2 11.6-11.6 11.6h-227c-6.4 0-11.6-5.2-11.6-11.6V124c0-6.4 5.2-11.6 11.6-11.6h227c6.4 0 11.6 5.2 11.6 11.6v325.6z"/>
5
+ <path fill="currentColor"
6
+ d="M401.05 0h-227c-21.3 0-38.6 17.3-38.6 38.6 0 7.5 6 13.5 13.5 13.5s13.5-6 13.5-13.5c0-6.4 5.2-11.6 11.6-11.6h227c6.4 0 11.6 5.2 11.6 11.6v325.7c0 6.4-5.2 11.6-11.6 11.6-7.5 0-13.5 6-13.5 13.5s6 13.5 13.5 13.5c21.3 0 38.6-17.3 38.6-38.6V38.6c0-21.3-17.3-38.6-38.6-38.6z"/></svg>
@@ -1,4 +1,4 @@
1
- import { Controller } from "stimulus";
1
+ import { Controller } from "@hotwired/stimulus";
2
2
 
3
3
  export default class extends Controller {
4
4
  static targets = ["count"];
@@ -0,0 +1,46 @@
1
+ import { Controller } from "@hotwired/stimulus";
2
+
3
+ export default class extends Controller {
4
+ static targets = ["button", "source"];
5
+
6
+ connect() {
7
+ if (!this.hasButtonTarget) return;
8
+
9
+ this.originalText = this.buttonTarget.innerText;
10
+ this.successDuration = 2000;
11
+ }
12
+
13
+ copy(event) {
14
+ event.preventDefault();
15
+
16
+ let text = this.sourceTarget.innerText;
17
+ const filter = this.data.get("filter");
18
+ if (filter) {
19
+ text = new RegExp(filter).exec(text)[0];
20
+ }
21
+ const temporaryInput = document.createElement("textarea");
22
+ temporaryInput.value = text;
23
+ document.body.appendChild(temporaryInput);
24
+ temporaryInput.select();
25
+ document.execCommand("copy");
26
+ document.body.removeChild(temporaryInput);
27
+
28
+ this.copied();
29
+ }
30
+
31
+ copied() {
32
+ if (!this.hasButtonTarget) return;
33
+
34
+ if (this.timeout) {
35
+ clearTimeout(this.timeout);
36
+ }
37
+
38
+ const copiedClass = this.data.get("copiedClass");
39
+ console.log(copiedClass);
40
+ this.buttonTarget.classList.add(copiedClass);
41
+
42
+ this.timeout = setTimeout(() => {
43
+ this.buttonTarget.classList.remove(copiedClass);
44
+ }, this.successDuration);
45
+ }
46
+ }
@@ -1,4 +1,4 @@
1
- import { Controller } from 'stimulus'
1
+ import { Controller } from "@hotwired/stimulus";
2
2
 
3
3
  export default class extends Controller {
4
4
  static targets = ["enable"];
@@ -15,9 +15,8 @@ export default class extends Controller {
15
15
  if (event.type.match(/rmp:select:.*/)) {
16
16
  if (event.detail.count > 0) {
17
17
  this.enable();
18
- }
19
- else {
20
- this.disable()
18
+ } else {
19
+ this.disable();
21
20
  }
22
21
  }
23
22
  }
@@ -1,4 +1,4 @@
1
- import { Controller } from "stimulus";
1
+ import { Controller } from "@hotwired/stimulus";
2
2
 
3
3
  export default class extends Controller {
4
4
  static targets = ["filter"];
@@ -1,18 +1,18 @@
1
- import { Controller } from "stimulus";
1
+ import { Controller } from "@hotwired/stimulus";
2
2
 
3
3
  export default class extends Controller {
4
4
  static targets = ["field"];
5
5
 
6
- clear(){
6
+ clear() {
7
7
  this.eventTarget.value = null;
8
- window.dispatchEvent(new CustomEvent('search-controller:submit', {}))
8
+ window.dispatchEvent(new CustomEvent("search-controller:submit", {}));
9
9
  }
10
10
 
11
11
  submit(event) {
12
12
  event.preventDefault();
13
13
 
14
- if (event.key === 'Enter' || event.type === 'click') {
15
- window.dispatchEvent(new CustomEvent('search-controller:submit', {}))
14
+ if (event.key === "Enter" || event.type === "click") {
15
+ window.dispatchEvent(new CustomEvent("search-controller:submit", {}));
16
16
  }
17
17
  }
18
18
  }
@@ -1,47 +1,52 @@
1
- import { Controller } from 'stimulus'
1
+ import { Controller } from "@hotwired/stimulus";
2
2
 
3
3
  export default class extends Controller {
4
- static targets = ['all', 'selectable']
4
+ static targets = ["all", "selectable"];
5
5
 
6
- selectAll (event) {
7
- const checked = event.target.checked
8
- this.allTarget.indeterminate = false
9
- this._setAllCheckboxes(checked)
10
- this._dispatch('change', { count: this.selectedCount })
6
+ selectAll(event) {
7
+ const checked = event.target.checked;
8
+ this.allTarget.indeterminate = false;
9
+ this._setAllCheckboxes(checked);
10
+ this._dispatch("change", { count: this.selectedCount });
11
11
  }
12
12
 
13
- onSelected () {
14
- this.allTarget.indeterminate = !!this._indeterminate
15
- this._dispatch('change', { count: this.selectedCount })
13
+ onSelected() {
14
+ this.allTarget.indeterminate = !!this._indeterminate;
15
+ this._dispatch("change", { count: this.selectedCount });
16
16
  }
17
17
 
18
- get selectedCount () {
19
- return this.selected.length
18
+ get selectedCount() {
19
+ return this.selected.length;
20
20
  }
21
21
 
22
- get selected () {
23
- return this.selectables.filter((c) => c.checked)
22
+ get selected() {
23
+ return this.selectables.filter((c) => c.checked);
24
24
  }
25
25
 
26
- get selectables () {
27
- return new Array(...this.selectableTargets)
26
+ get selectables() {
27
+ return new Array(...this.selectableTargets);
28
28
  }
29
29
 
30
- _setAllCheckboxes (checked) {
30
+ _setAllCheckboxes(checked) {
31
31
  this.selectables.forEach((el) => {
32
- const checkbox = el
32
+ const checkbox = el;
33
33
 
34
34
  if (!checkbox.disabled) {
35
- checkbox.checked = checked
35
+ checkbox.checked = checked;
36
36
  }
37
- })
37
+ });
38
38
  }
39
39
 
40
- get _indeterminate () {
41
- return this.selected.length !== this.selectableTargets.length && this.selected.length > 0
40
+ get _indeterminate() {
41
+ return (
42
+ this.selected.length !== this.selectableTargets.length &&
43
+ this.selected.length > 0
44
+ );
42
45
  }
43
46
 
44
- _dispatch (name, detail) {
45
- window.dispatchEvent(new CustomEvent(`rmp:select:${name}`, { bubbles: true, detail }))
47
+ _dispatch(name, detail) {
48
+ window.dispatchEvent(
49
+ new CustomEvent(`rmp:select:${name}`, { bubbles: true, detail })
50
+ );
46
51
  }
47
52
  }
@@ -1,88 +1,96 @@
1
- import '../stylesheets/rails-mini-profiler.scss'
1
+ import "../stylesheets/rails-mini-profiler.scss";
2
2
 
3
- import tippy from 'tippy.js'
4
- import 'tippy.js/dist/tippy.css'
3
+ import tippy from "tippy.js";
4
+ import "tippy.js/dist/tippy.css";
5
5
 
6
- import { Application } from 'stimulus'
7
- import { Dropdown } from 'tailwindcss-stimulus-components'
8
- import Checklist from '../js/checklist_controller'
9
- import Selectable from '../js/select_controller'
10
- import Filter from '../js/filter_controller'
11
- import Search from '../js/search_controller'
12
- import Enable from '../js/enable_controller'
6
+ import { Application } from "@hotwired/stimulus";
7
+ import { Dropdown } from "tailwindcss-stimulus-components";
8
+ import Checklist from "../js/checklist_controller";
9
+ import Selectable from "../js/select_controller";
10
+ import Filter from "../js/filter_controller";
11
+ import Search from "../js/search_controller";
12
+ import Enable from "../js/enable_controller";
13
+ import Clipboard from "../js/clipboard_controller";
13
14
 
14
15
  const application = Application.start();
15
16
 
16
- application.register('dropdown', Dropdown)
17
- application.register('checklist', Checklist)
18
- application.register('selectable', Selectable)
19
- application.register('filters', Filter)
20
- application.register('search', Search)
21
- application.register('enable', Enable)
22
-
17
+ application.register("dropdown", Dropdown);
18
+ application.register("checklist", Checklist);
19
+ application.register("selectable", Selectable);
20
+ application.register("filters", Filter);
21
+ application.register("search", Search);
22
+ application.register("enable", Enable);
23
+ application.register("clipboard", Clipboard);
23
24
 
24
25
  function setupTraceSearch() {
25
- const traceNameSearch = document.getElementById('trace-search')
26
+ const traceNameSearch = document.getElementById("trace-search");
26
27
  if (traceNameSearch) {
27
- traceNameSearch.addEventListener('keyup', function (event) {
28
- if (event.key === 'Enter') {
29
- event.preventDefault()
30
- document.getElementById('trace-form').submit()
28
+ traceNameSearch.addEventListener("keyup", function (event) {
29
+ if (event.key === "Enter") {
30
+ event.preventDefault();
31
+ document.getElementById("trace-form").submit();
31
32
  }
32
- })
33
+ });
33
34
  }
34
35
  }
35
36
 
36
37
  function setupRequestTable() {
37
- const profiledRequestTable = document.getElementById('profiled-requests-table');
38
+ const profiledRequestTable = document.getElementById(
39
+ "profiled-requests-table"
40
+ );
38
41
  if (profiledRequestTable) {
39
42
  const rows = profiledRequestTable.rows;
40
43
  for (let i = 1; i < rows.length; i++) {
41
- const currentRow = profiledRequestTable.rows[i]
42
- const link = currentRow.dataset.link
44
+ const currentRow = profiledRequestTable.rows[i];
45
+ const link = currentRow.dataset.link;
43
46
  const createClickHandler = function () {
44
47
  return function () {
45
- window.location.href = link
46
- }
47
- }
48
+ window.location.href = link;
49
+ };
50
+ };
48
51
  if (link) {
49
- currentRow.onclick = createClickHandler(currentRow)
50
-
52
+ currentRow.onclick = createClickHandler(currentRow);
51
53
  }
52
54
  }
53
55
  }
54
56
  }
55
57
 
56
- function setupTraceBars () {
57
- const traceBars = document.querySelectorAll('.trace-bar')
58
+ function setupTraceBars() {
59
+ const traceBars = document.querySelectorAll(".trace-bar");
58
60
  traceBars.forEach((bar) => {
59
- const popover = bar.children[0]
61
+ const popover = bar.children[0];
60
62
  tippy(bar, {
61
- trigger: 'click',
63
+ trigger: "click",
62
64
  content: popover,
63
- theme: 'rmp',
64
- maxWidth: '700px',
65
- placement: 'bottom',
65
+ theme: "rmp",
66
+ maxWidth: "700px",
67
+ placement: "bottom",
66
68
  interactive: true,
67
- onShow (instance) {
68
- instance.popper.querySelector('.popover-close').addEventListener('click', () => {
69
- instance.hide()
70
- })
69
+ onShow(instance) {
70
+ instance.popper
71
+ .querySelector(".popover-close")
72
+ .addEventListener("click", () => {
73
+ instance.hide();
74
+ });
71
75
  },
72
- onHide (instance) {
73
- instance.popper.querySelector('.popover-close').removeEventListener('click', () => {
74
- instance.hide()
75
- })
76
+ onHide(instance) {
77
+ instance.popper
78
+ .querySelector(".popover-close")
79
+ .removeEventListener("click", () => {
80
+ instance.hide();
81
+ });
76
82
  },
77
- })
78
- })
83
+ });
84
+ });
79
85
  }
80
86
 
81
-
82
87
  // Trace Bar Popovers
83
- document.addEventListener('DOMContentLoaded', () => {
84
- setupRequestTable();
85
- setupTraceBars();
86
- setupTraceSearch();
87
- }, false)
88
-
88
+ document.addEventListener(
89
+ "DOMContentLoaded",
90
+ () => {
91
+ setupRequestTable();
92
+ setupTraceBars();
93
+ setupTraceSearch();
94
+ },
95
+ false
96
+ );
@@ -1,6 +1,6 @@
1
1
  .trace-list {
2
2
  padding: 0;
3
- margin: 0;
3
+ margin: 2rem 0;
4
4
  }
5
5
 
6
6
  .trace {
@@ -80,3 +80,31 @@
80
80
  margin-top: 1em;
81
81
  border-collapse: collapse;
82
82
  }
83
+
84
+ .backtrace {
85
+ display: flex;
86
+ flex-direction: row;
87
+ align-items: center;
88
+ justify-content: space-between;
89
+ padding: 0.5em;
90
+ background: var(--grey-100);
91
+ }
92
+
93
+ .backtrace button {
94
+ width: 20px;
95
+ height: 20px;
96
+ padding: 0;
97
+ margin: 0;
98
+ background: none;
99
+ color: var(--grey-500);
100
+ transition: color 200ms ease-in-out;
101
+ }
102
+
103
+ .backtrace button.copied {
104
+ color: var(--green-400);
105
+ }
106
+
107
+ .backtrace button svg {
108
+ width: 20px;
109
+ height: 20px;
110
+ }
@@ -32,7 +32,22 @@
32
32
 
33
33
  <% if trace.backtrace %>
34
34
  <section class="popover-footer">
35
- <pre><%= trace.backtrace %></pre>
35
+ <div
36
+ class="backtrace"
37
+ data-controller="clipboard"
38
+ data-clipboard-filter=".+?(?=:in)"
39
+ data-clipboard-copied-class="copied"
40
+ >
41
+ <pre data-clipboard-target="source"><%= trace.backtrace %></pre>
42
+ <button
43
+ title="Copy to clipboard"
44
+ type="button"
45
+ data-action="clipboard#copy"
46
+ data-clipboard-target="button"
47
+ >
48
+ <%= inline_svg('copy.svg') %>
49
+ </button>
50
+ </div>
36
51
  </section>
37
52
  <% end %>
38
53
  </div>
@@ -3,7 +3,7 @@
3
3
  <%= csrf_meta_tags %>
4
4
  <%= csp_meta_tag %>
5
5
 
6
- <% if defined?(Webpacker::Engine) %>
6
+ <% if defined?(Webpacker::Engine) && RailsMiniProfiler.configuration.ui.webpacker_enabled %>
7
7
  <%= javascript_pack_tag "rails-mini-profiler" %>
8
8
  <%= stylesheet_pack_tag 'rails-mini-profiler' %>
9
9
  <% else %>
@@ -23,6 +23,7 @@ RailsMiniProfiler.configure do |config|
23
23
  # config.ui.badge_enabled = true
24
24
  # config.ui.badge_position = 'top-left'
25
25
  # config.ui.page_size = 25
26
+ # config.ui.webpacker_enabled = true
26
27
 
27
28
  # Customize how users are detected
28
29
  config.user_provider = proc { |env| Rack::Request.new(env).ip }
@@ -59,7 +59,7 @@ module RailsMiniProfiler
59
59
  #
60
60
  # @return String The badge HTML content to be injected
61
61
  def badge_content
62
- html = IO.read(File.expand_path('../../app/views/rails_mini_profiler/badge.html.erb', __dir__))
62
+ html = File.read(File.expand_path('../../app/views/rails_mini_profiler/badge.html.erb', __dir__))
63
63
  @position = css_position
64
64
  template = ERB.new(html)
65
65
  template.result(binding)
@@ -11,6 +11,8 @@ module RailsMiniProfiler
11
11
  # @return [String] the position of the interactive HTML badge
12
12
  # @!attribute page_size
13
13
  # @return [Integer] how many items to render per page in list views
14
+ # @!attribute webpacker_enabled
15
+ # @return [Boolean] if webpacker assets should be used. Disable to fall back to the asset pipeline
14
16
  class UserInterface
15
17
  class << self
16
18
  # Construct a new UI configuration instance
@@ -31,7 +33,8 @@ module RailsMiniProfiler
31
33
 
32
34
  attr_accessor :badge_enabled,
33
35
  :badge_position,
34
- :page_size
36
+ :page_size,
37
+ :webpacker_enabled
35
38
 
36
39
  def initialize(**kwargs)
37
40
  defaults!
@@ -43,6 +46,7 @@ module RailsMiniProfiler
43
46
  @badge_enabled = true
44
47
  @badge_position = 'top-left'
45
48
  @page_size = 25
49
+ @webpacker_enabled = true
46
50
  end
47
51
  end
48
52
  end
@@ -34,7 +34,9 @@ module RailsMiniProfiler
34
34
  def ignored_path?
35
35
  return true if /#{Engine.routes.find_script_name({})}/.match?(@request.path)
36
36
 
37
- return true if /assets/.match?(@request.path)
37
+ return true if asset_path?
38
+
39
+ return true if actioncable_request?
38
40
 
39
41
  ignored_paths = @configuration.skip_paths
40
42
  return true if Regexp.union(ignored_paths).match?(@request.path)
@@ -42,6 +44,22 @@ module RailsMiniProfiler
42
44
  false
43
45
  end
44
46
 
47
+ # Is the current request an asset request, e.g. to webpacker packs or assets?
48
+ #
49
+ # @return [Boolean] if the request path matches packs or assets
50
+ def asset_path?
51
+ %r{^/packs}.match?(@request.path) || %r{^/assets}.match?(@request.path)
52
+ end
53
+
54
+ # Is the current request an actioncable ping
55
+ #
56
+ # @return [Boolean] if the request path matches the mount path of actioncable
57
+ def actioncable_request?
58
+ return false unless defined?(ActionCable)
59
+
60
+ /#{ActionCable.server.config.mount_path}/.match?(@request.path)
61
+ end
62
+
45
63
  # Is the profiler enabled?
46
64
  #
47
65
  # Takes into account the current request env to decide if the profiler is enabled.
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module RailsMiniProfiler
4
- VERSION = '0.5.0'
4
+ VERSION = '0.6.0'
5
5
  end
@@ -0,0 +1,6 @@
1
+ <svg xmlns="http://www.w3.org/2000/svg"
2
+ viewBox="0 0 488.3 488.3" style="enable-background:new 0 0 488.3 488.3" xml:space="preserve">
3
+ <path fill="currentColor"
4
+ d="M314.25 85.4h-227c-21.3 0-38.6 17.3-38.6 38.6v325.7c0 21.3 17.3 38.6 38.6 38.6h227c21.3 0 38.6-17.3 38.6-38.6V124c-.1-21.3-17.4-38.6-38.6-38.6zm11.5 364.2c0 6.4-5.2 11.6-11.6 11.6h-227c-6.4 0-11.6-5.2-11.6-11.6V124c0-6.4 5.2-11.6 11.6-11.6h227c6.4 0 11.6 5.2 11.6 11.6v325.6z"/>
5
+ <path fill="currentColor"
6
+ d="M401.05 0h-227c-21.3 0-38.6 17.3-38.6 38.6 0 7.5 6 13.5 13.5 13.5s13.5-6 13.5-13.5c0-6.4 5.2-11.6 11.6-11.6h227c6.4 0 11.6 5.2 11.6 11.6v325.7c0 6.4-5.2 11.6-11.6 11.6-7.5 0-13.5 6-13.5 13.5s6 13.5 13.5 13.5c21.3 0 38.6-17.3 38.6-38.6V38.6c0-21.3-17.3-38.6-38.6-38.6z"/></svg>
@@ -1 +1 @@
1
- @import url("https://fonts.googleapis.com/css2?family=Open+Sans:wght@400;600;700&display=swap");.flash{padding:1rem;margin-top:1rem;border-radius:5px}.flash-error{background:var(--red-500);color:#fff}.flash-notice{background:var(--green-400);color:#fff}#wrapper{width:100%;height:100vh}#speedscope-iframe{width:100%;height:100%;border:none}.header{display:flex;justify-content:center;padding:1.5rem 0;margin:0;background:var(--primary);box-shadow:0 0 20px 0 rgba(0,0,0,.2)}.header a{color:#fff;text-decoration:none}.nav{width:var(--main-width);justify-content:space-between}.home,.nav{display:flex}.home{align-items:center;text-decoration:none}.home-logo{width:64px;height:64px}.home-title{padding:0 0 0 1rem;margin:0}.header-links{padding:0;margin:0;font-weight:700;list-style:none}.header-links,.placeholder{display:flex;align-items:center}.placeholder{width:100%;flex-direction:column;justify-content:center;padding-bottom:2rem}.placeholder-image{width:30%;height:30%;-webkit-filter:grayscale(1) brightness(2.5)}.placeholder-text{padding:1rem 0;text-align:center}.placeholder-link,.placeholder-link:visited,.placeholder-text{color:var(--grey-400)}.placeholder-link:hover{color:var(--grey-900)}.table{width:100%;border:1px hidden var(--border-color);border-collapse:collapse;border-radius:5px;box-shadow:0 0 0 1px var(--border-color);table-layout:fixed}.table td,.table th{padding:.5rem 1rem}.table thead tr{border:1px hidden var(--border-color);box-shadow:0 0 0 1px var(--border-color);color:var(--grey-400)}.table tr:nth-child(2n){background:var(--grey-50)}.table thead th{font-weight:400}.table-filter-icon{width:14px;margin-left:.5rem}.table tbody tr:not(.no-row){border:1px solid var(--border-color);color:var(--grey-700);cursor:pointer}.table tbody tr:not(.no-row):hover{background:var(--grey-100)}.request-checkbox{z-index:1;width:1rem;height:1rem}.dropdown-body{padding:.33rem .5rem}.dropdown-search-field{padding:.5rem;border:1px solid var(--grey-400);border-radius:5px;color:var(--grey-700)}.dropdown-toggle{display:flex;align-items:center;color:inherit}.dropdown-toggle:hover{color:var(--grey-900)}.dropdown-container{position:absolute;z-index:1;overflow:hidden;min-width:240px;box-sizing:border-box;border:1px solid var(--grey-200);margin-top:.3em;background:#fff;border-radius:5px;box-shadow:0 8px 30px rgba(0,0,0,.12);color:var(--grey-400);cursor:default}.dropdown-container,.dropdown-search,.dropdown-search button{display:flex;flex-direction:column}.dropdown-entry{display:flex;padding:.33rem 1rem;text-decoration:none}.dropdown-entry:hover{background:var(--grey-100);color:var(--grey-900)}.dropdown-entry input{margin-right:.5em}.dropdown-header{display:flex;align-items:center;justify-content:space-between;padding:.5rem 1rem;border-bottom:1px solid var(--grey-200);background:var(--grey-100);font-size:.833rem;text-align:left}.dropdown-header button{padding:0;border:none;background:none;color:var(--grey-500);font-size:.833rem;outline:none;text-decoration:underline}.dropdown-header button:hover{box-shadow:none;color:var(--grey-900)}.dropdown-footer{width:100%;padding:.5rem;border:none;background:var(--red-500);border-radius:0;color:#fff;font-weight:600;outline:none}.dropdown-footer:hover{background:var(--red-600)}.dropdown-search-button{display:inline-block;padding:.5em;border:none;background:var(--red-500);border-radius:5px;color:#fff;cursor:pointer;font-size:1rem;font-weight:600;text-align:center;text-decoration:none}.dropdown-search-button:hover{background:var(--red-600)}.request-path{overflow:hidden;max-width:280px;text-overflow:ellipsis;white-space:nowrap}main{display:flex;width:100%;justify-content:center}.main-section{width:var(--main-width)}.search-field{box-sizing:border-box;padding:.5rem;border:1px solid var(--grey-400);border-radius:5px}.request-details-data{display:flex;padding:1rem 0}.request-details-actions{display:flex;align-items:center;justify-content:space-between;padding:0 0 1rem;margin:0}.data-item{display:flex;flex-direction:column;align-items:flex-start;padding:0;margin-right:3rem;list-style:none}.data-item small{color:var(--grey-400)}.data-item span{margin:.25rem 0}[class*=request-method-get],[class*=request-status-2]{background:var(--green-400)!important;color:#fff}[class*=request-method-patch],[class*=request-method-put],[class*=request-status-4]{background:var(--yellow-400)!important;color:#fff}[class*=request-method-delete],[class*=request-status-5]{background:var(--red-500)!important;color:#fff}.flamegraph-button button{background:var(--grey-200)}.clear-action button{background:var(--red-500);color:#fff;font-weight:600}.clear-action button:hover{background:var(--red-600)}.profiled-requests-header{display:flex;flex-direction:row;align-items:center;justify-content:space-between}.trace-list{padding:0;margin:0}.trace{display:flex;align-items:center;justify-content:flex-start;padding:.25em 0;list-style:none}.trace:nth-child(odd){background:var(--grey-100)}.trace .trace-bar{position:relative;height:16px;padding:0;margin:0;background:linear-gradient(to top right,var(--grey-500),var(--grey-400));cursor:pointer}.instantiation-trace .trace-bar{background:linear-gradient(to top right,var(--green-400),var(--green-300))}.sequel-trace .trace-bar{background:linear-gradient(to top right,var(--green-500),var(--green-400))}.controller-trace .trace-bar{background:linear-gradient(to top right,var(--yellow-500),var(--yellow-400))}.render-partial-trace .trace-bar,.render-template-trace .trace-bar{background:linear-gradient(to top right,var(--blue-500),var(--blue-400))}.trace-name{overflow:hidden;box-sizing:border-box;padding:0 .5em;margin:0;color:var(--grey-400);font-size:14px;text-align:right;text-overflow:ellipsis}.trace-payload{margin:0}.sequel-trace-query{padding:1em;background:var(--grey-100)}.sequel-trace-binds,.sequel-trace-query{overflow:auto;max-height:100px;white-space:pre-wrap}.sequel-trace-binds{padding:.5em 1em;margin:0 0 1em;background:var(--grey-50);font-size:12px}.trace-table{width:100%;border:1px hidden var(--border-color);margin-top:1em;border-collapse:collapse}.pagy-nav{display:flex;align-items:center;justify-content:center;padding:1em 0}.pagy-nav>.page.active,.pagy-nav>.page.disabled,.pagy-nav>.page>a{padding:.5rem 1rem;border:1px solid var(--border-color);border-right:none;background:#fff;color:var(--grey-900);cursor:pointer;text-decoration:none}.pagy-nav>.page.prev.disabled,.pagy-nav>.page.prev a{border-radius:5px 0 0 5px}.pagy-nav>.page.next.disabled,.pagy-nav>.page.next a{border-right:1px solid var(--border-color);border-radius:0 5px 5px 0}.pagy-nav>.page.active{border-color:var(--red-500);color:#fff;cursor:default}.pagy-nav>.page.active,.pagy-nav>.page.active:hover{background:var(--red-500)}.pagy-nav>.page.disabled{color:var(--grey-500);cursor:default}.pagy-nav>.page.disabled:hover{background:#fff}.pagy-nav>.page.active:hover,.pagy-nav>.page.disabled:hover,.pagy-nav>.page>a:hover{background:var(--grey-100)}.page-header{padding:2rem 0}@font-face{font-family:Open Sans;font-style:normal;font-weight:400}@font-face{font-family:Open Sans;font-style:normal;font-weight:600}@font-face{font-family:Open Sans;font-style:normal;font-weight:700}html{width:100%;height:100%;font-family:Open Sans,monospace;--grey-50:#f9fafb;--grey-100:#f3f4f6;--grey-200:#e5e7eb;--grey-400:#9ca3af;--grey-500:#6b7280;--grey-700:#374151;--grey-900:#111827;--red-400:#f87171;--red-500:#ef4444;--red-600:#dc2626;--yellow-400:#fbbf24;--yellow-500:#fbbf24;--yellow-600:#d97706;--yellow-700:#b45309;--green-300:#6ee7b7;--green-400:#34d399;--green-500:#10b981;--blue-400:#60a5fa;--blue-500:#3b82f6;--main-width:1056px;--primary:var(--red-600);--border-color:var(--grey-200);--text-color:var(--grey-900)}*,body,html{padding:0;margin:0}body{width:100%;height:100%;color:var(--text-color)}.button,button{display:inline-block;padding:.5em;border:none;border-radius:.25rem;cursor:pointer;font-size:1rem;text-align:center;text-decoration:none}.button:disabled,button:disabled{background:var(--grey-200);cursor:not-allowed}button:hover{box-shadow:0 .25rem .25rem 0 var(--grey-50)}button.none{padding:0;border:none;background:none;outline:none}button.none:hover{box-shadow:none}.text-center{text-align:center}.text-left{text-align:left}.text-right{text-align:right}.hidden{display:none}.flex-row{display:flex;flex-direction:row}.flex-column{display:flex;flex-direction:column}.pill{padding:.1rem .4rem;margin:.2rem 0;background:var(--grey-200);border-radius:5px;font-size:.9rem;font-weight:600;letter-spacing:.1rem}.popover{display:flex;width:600px;flex-direction:column;padding:1em;color:#000}.popover-header{display:flex;flex-direction:row;align-items:center;justify-content:space-between;padding-bottom:1em}.popover-description{padding:0;margin:0}.popover-close{padding:0;background:transparent;color:var(--grey-400);font-size:20px;font-weight:700}.popover-body{padding:1em 0}.popover-footer{border-top:1px solid var(--grey-50)}.tippy-box[data-theme~=rmp]{background:#fff;border-radius:5px;box-shadow:8px 0 30px 4px rgba(0,0,0,.2),8px 4px 10px 0 rgba(0,0,0,.05);transition:all .2s cubic-bezier(.19,1,.22,1)}.tippy-box[data-theme~=rmp][data-placement^=top]>.tippy-arrow:before{border-top-color:#fff}.tippy-box[data-theme~=rmp][data-placement^=bottom]>.tippy-arrow:before{border-bottom-color:#fff}.tippy-box[data-theme~=rmp][data-placement^=left]>.tippy-arrow:before{border-left-color:#fff}.tippy-box[data-theme~=rmp][data-placement^=right]>.tippy-arrow:before{border-right-color:#fff}
1
+ @import url("https://fonts.googleapis.com/css2?family=Open+Sans:wght@400;600;700&display=swap");.flash{border-radius:5px;margin-top:1rem;padding:1rem}.flash-error{background:var(--red-500);color:#fff}.flash-notice{background:var(--green-400);color:#fff}#wrapper{height:100vh;width:100%}#speedscope-iframe{border:none;height:100%;width:100%}.header{background:var(--primary);box-shadow:0 0 20px 0 rgba(0,0,0,.2);display:flex;justify-content:center;margin:0;padding:1.5rem 0}.header a{color:#fff;text-decoration:none}.nav{justify-content:space-between;width:var(--main-width)}.home,.nav{display:flex}.home{align-items:center;text-decoration:none}.home-logo{height:64px;width:64px}.home-title{margin:0;padding:0 0 0 1rem}.header-links{font-weight:700;list-style:none;margin:0;padding:0}.header-links,.placeholder{align-items:center;display:flex}.placeholder{flex-direction:column;justify-content:center;padding-bottom:2rem;width:100%}.placeholder-image{-webkit-filter:grayscale(1) brightness(2.5);height:30%;width:30%}.placeholder-text{padding:1rem 0;text-align:center}.placeholder-link,.placeholder-link:visited,.placeholder-text{color:var(--grey-400)}.placeholder-link:hover{color:var(--grey-900)}.table{border:1px hidden var(--border-color);border-collapse:collapse;border-radius:5px;box-shadow:0 0 0 1px var(--border-color);table-layout:fixed;width:100%}.table td,.table th{padding:.5rem 1rem}.table thead tr{border:1px hidden var(--border-color);box-shadow:0 0 0 1px var(--border-color);color:var(--grey-400)}.table tr:nth-child(2n){background:var(--grey-50)}.table thead th{font-weight:400}.table-filter-icon{margin-left:.5rem;width:14px}.table tbody tr:not(.no-row){border:1px solid var(--border-color);color:var(--grey-700);cursor:pointer}.table tbody tr:not(.no-row):hover{background:var(--grey-100)}.request-checkbox{height:1rem;width:1rem;z-index:1}.dropdown-body{padding:.33rem .5rem}.dropdown-search-field{border:1px solid var(--grey-400);border-radius:5px;color:var(--grey-700);padding:.5rem}.dropdown-toggle{align-items:center;color:inherit;display:flex}.dropdown-toggle:hover{color:var(--grey-900)}.dropdown-container{background:#fff;border:1px solid var(--grey-200);border-radius:5px;box-shadow:0 8px 30px rgba(0,0,0,.12);box-sizing:border-box;color:var(--grey-400);cursor:default;margin-top:.3em;min-width:240px;overflow:hidden;position:absolute;z-index:1}.dropdown-container,.dropdown-search,.dropdown-search button{display:flex;flex-direction:column}.dropdown-entry{display:flex;padding:.33rem 1rem;text-decoration:none}.dropdown-entry:hover{background:var(--grey-100);color:var(--grey-900)}.dropdown-entry input{margin-right:.5em}.dropdown-header{align-items:center;background:var(--grey-100);border-bottom:1px solid var(--grey-200);display:flex;font-size:.833rem;justify-content:space-between;padding:.5rem 1rem;text-align:left}.dropdown-header button{background:none;border:none;color:var(--grey-500);font-size:.833rem;outline:none;padding:0;text-decoration:underline}.dropdown-header button:hover{box-shadow:none;color:var(--grey-900)}.dropdown-footer{background:var(--red-500);border:none;border-radius:0;color:#fff;font-weight:600;outline:none;padding:.5rem;width:100%}.dropdown-footer:hover{background:var(--red-600)}.dropdown-search-button{background:var(--red-500);border:none;border-radius:5px;color:#fff;cursor:pointer;display:inline-block;font-size:1rem;font-weight:600;padding:.5em;text-align:center;text-decoration:none}.dropdown-search-button:hover{background:var(--red-600)}.request-path{max-width:280px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}main{display:flex;justify-content:center;width:100%}.main-section{width:var(--main-width)}.search-field{border:1px solid var(--grey-400);border-radius:5px;box-sizing:border-box;padding:.5rem}.request-details-data{display:flex;padding:1rem 0}.request-details-actions{align-items:center;display:flex;justify-content:space-between;margin:0;padding:0 0 1rem}.data-item{align-items:flex-start;display:flex;flex-direction:column;list-style:none;margin-right:3rem;padding:0}.data-item small{color:var(--grey-400)}.data-item span{margin:.25rem 0}[class*=request-method-get],[class*=request-status-2]{background:var(--green-400)!important;color:#fff}[class*=request-method-patch],[class*=request-method-put],[class*=request-status-4]{background:var(--yellow-400)!important;color:#fff}[class*=request-method-delete],[class*=request-status-5]{background:var(--red-500)!important;color:#fff}.flamegraph-button button{background:var(--grey-200)}.clear-action button{background:var(--red-500);color:#fff;font-weight:600}.clear-action button:hover{background:var(--red-600)}.profiled-requests-header{align-items:center;display:flex;flex-direction:row;justify-content:space-between}.trace-list{margin:2rem 0;padding:0}.trace{align-items:center;display:flex;justify-content:flex-start;list-style:none;padding:.25em 0}.trace:nth-child(odd){background:var(--grey-100)}.trace .trace-bar{background:linear-gradient(to top right,var(--grey-500),var(--grey-400));cursor:pointer;height:16px;margin:0;padding:0;position:relative}.instantiation-trace .trace-bar{background:linear-gradient(to top right,var(--green-400),var(--green-300))}.sequel-trace .trace-bar{background:linear-gradient(to top right,var(--green-500),var(--green-400))}.controller-trace .trace-bar{background:linear-gradient(to top right,var(--yellow-500),var(--yellow-400))}.render-partial-trace .trace-bar,.render-template-trace .trace-bar{background:linear-gradient(to top right,var(--blue-500),var(--blue-400))}.trace-name{box-sizing:border-box;color:var(--grey-400);font-size:14px;margin:0;overflow:hidden;padding:0 .5em;text-align:right;text-overflow:ellipsis}.trace-payload{margin:0}.sequel-trace-query{background:var(--grey-100);padding:1em}.sequel-trace-binds,.sequel-trace-query{max-height:100px;overflow:auto;white-space:pre-wrap}.sequel-trace-binds{background:var(--grey-50);font-size:12px;margin:0 0 1em;padding:.5em 1em}.trace-table{border:1px hidden var(--border-color);border-collapse:collapse;margin-top:1em;width:100%}.backtrace{align-items:center;background:var(--grey-100);display:flex;flex-direction:row;justify-content:space-between;padding:.5em}.backtrace button{background:none;color:var(--grey-500);height:20px;margin:0;padding:0;transition:color .2s ease-in-out;width:20px}.backtrace button.copied{color:var(--green-400)}.backtrace button svg{height:20px;width:20px}.pagy-nav{align-items:center;display:flex;justify-content:center;padding:1em 0}.pagy-nav>.page.active,.pagy-nav>.page.disabled,.pagy-nav>.page>a{background:#fff;border:1px solid var(--border-color);border-right:none;color:var(--grey-900);cursor:pointer;padding:.5rem 1rem;text-decoration:none}.pagy-nav>.page.prev.disabled,.pagy-nav>.page.prev a{border-radius:5px 0 0 5px}.pagy-nav>.page.next.disabled,.pagy-nav>.page.next a{border-radius:0 5px 5px 0;border-right:1px solid var(--border-color)}.pagy-nav>.page.active{border-color:var(--red-500);color:#fff;cursor:default}.pagy-nav>.page.active,.pagy-nav>.page.active:hover{background:var(--red-500)}.pagy-nav>.page.disabled{color:var(--grey-500);cursor:default}.pagy-nav>.page.disabled:hover{background:#fff}.pagy-nav>.page.active:hover,.pagy-nav>.page.disabled:hover,.pagy-nav>.page>a:hover{background:var(--grey-100)}.page-header{padding:2rem 0}@font-face{font-family:Open Sans;font-style:normal;font-weight:400}@font-face{font-family:Open Sans;font-style:normal;font-weight:600}@font-face{font-family:Open Sans;font-style:normal;font-weight:700}html{--grey-50:#f9fafb;--grey-100:#f3f4f6;--grey-200:#e5e7eb;--grey-400:#9ca3af;--grey-500:#6b7280;--grey-700:#374151;--grey-900:#111827;--red-400:#f87171;--red-500:#ef4444;--red-600:#dc2626;--yellow-400:#fbbf24;--yellow-500:#fbbf24;--yellow-600:#d97706;--yellow-700:#b45309;--green-300:#6ee7b7;--green-400:#34d399;--green-500:#10b981;--blue-400:#60a5fa;--blue-500:#3b82f6;--main-width:1056px;--primary:var(--red-600);--border-color:var(--grey-200);--text-color:var(--grey-900);font-family:Open Sans,monospace;height:100%;width:100%}*,body,html{margin:0;padding:0}body{color:var(--text-color);height:100%;width:100%}.button,button{border:none;border-radius:.25rem;cursor:pointer;display:inline-block;font-size:1rem;padding:.5em;text-align:center;text-decoration:none}.button:disabled,button:disabled{background:var(--grey-200);cursor:not-allowed}button:hover{box-shadow:0 .25rem .25rem 0 var(--grey-50)}button.none{background:none;border:none;outline:none;padding:0}button.none:hover{box-shadow:none}.text-center{text-align:center}.text-left{text-align:left}.text-right{text-align:right}.hidden{display:none}.flex-row{display:flex;flex-direction:row}.flex-column{display:flex;flex-direction:column}.pill{background:var(--grey-200);border-radius:5px;font-size:.9rem;font-weight:600;letter-spacing:.1rem;margin:.2rem 0;padding:.1rem .4rem}.popover{color:#000;display:flex;flex-direction:column;padding:1em;width:600px}.popover-header{align-items:center;display:flex;flex-direction:row;justify-content:space-between;padding-bottom:1em}.popover-description{margin:0;padding:0}.popover-close{background:transparent;color:var(--grey-400);font-size:20px;font-weight:700;padding:0}.popover-body{padding:1em 0}.popover-footer{border-top:1px solid var(--grey-50)}.tippy-box[data-theme~=rmp]{background:#fff;border-radius:5px;box-shadow:8px 0 30px 4px rgba(0,0,0,.2),8px 4px 10px 0 rgba(0,0,0,.05);transition:all .2s cubic-bezier(.19,1,.22,1)}.tippy-box[data-theme~=rmp][data-placement^=top]>.tippy-arrow:before{border-top-color:#fff}.tippy-box[data-theme~=rmp][data-placement^=bottom]>.tippy-arrow:before{border-bottom-color:#fff}.tippy-box[data-theme~=rmp][data-placement^=left]>.tippy-arrow:before{border-left-color:#fff}.tippy-box[data-theme~=rmp][data-placement^=right]>.tippy-arrow:before{border-right-color:#fff}
@@ -1 +1 @@
1
- !function(e){"function"==typeof define&&define.amd?define(e):e()}((function(){"use strict";var e="top",t="bottom",n="right",r="left",i="auto",o=[e,t,n,r],s="start",a="end",c="viewport",u="popper",l=o.reduce((function(e,t){return e.concat([t+"-"+s,t+"-"+a])}),[]),f=[].concat(o,[i]).reduce((function(e,t){return e.concat([t,t+"-"+s,t+"-"+a])}),[]),p=["beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite"];function d(e){return e?(e.nodeName||"").toLowerCase():null}function h(e){if(null==e)return window;if("[object Window]"!==e.toString()){var t=e.ownerDocument;return t&&t.defaultView||window}return e}function m(e){return e instanceof h(e).Element||e instanceof Element}function g(e){return e instanceof h(e).HTMLElement||e instanceof HTMLElement}function y(e){return"undefined"!=typeof ShadowRoot&&(e instanceof h(e).ShadowRoot||e instanceof ShadowRoot)}var v={name:"applyStyles",enabled:!0,phase:"write",fn:function(e){var t=e.state;Object.keys(t.elements).forEach((function(e){var n=t.styles[e]||{},r=t.attributes[e]||{},i=t.elements[e];g(i)&&d(i)&&(Object.assign(i.style,n),Object.keys(r).forEach((function(e){var t=r[e];!1===t?i.removeAttribute(e):i.setAttribute(e,!0===t?"":t)})))}))},effect:function(e){var t=e.state,n={popper:{position:t.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(t.elements.popper.style,n.popper),t.styles=n,t.elements.arrow&&Object.assign(t.elements.arrow.style,n.arrow),function(){Object.keys(t.elements).forEach((function(e){var r=t.elements[e],i=t.attributes[e]||{},o=Object.keys(t.styles.hasOwnProperty(e)?t.styles[e]:n[e]).reduce((function(e,t){return e[t]="",e}),{});g(r)&&d(r)&&(Object.assign(r.style,o),Object.keys(i).forEach((function(e){r.removeAttribute(e)})))}))}},requires:["computeStyles"]};function b(e){return e.split("-")[0]}var w=Math.round;function O(e,t){void 0===t&&(t=!1);var n=e.getBoundingClientRect(),r=1,i=1;return g(e)&&t&&(r=n.width/e.offsetWidth||1,i=n.height/e.offsetHeight||1),{width:w(n.width/r),height:w(n.height/i),top:w(n.top/i),right:w(n.right/r),bottom:w(n.bottom/i),left:w(n.left/r),x:w(n.left/r),y:w(n.top/i)}}function E(e){var t=O(e),n=e.offsetWidth,r=e.offsetHeight;return Math.abs(t.width-n)<=1&&(n=t.width),Math.abs(t.height-r)<=1&&(r=t.height),{x:e.offsetLeft,y:e.offsetTop,width:n,height:r}}function T(e,t){var n=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(n&&y(n)){var r=t;do{if(r&&e.isSameNode(r))return!0;r=r.parentNode||r.host}while(r)}return!1}function A(e){return h(e).getComputedStyle(e)}function k(e){return["table","td","th"].indexOf(d(e))>=0}function x(e){return((m(e)?e.ownerDocument:e.document)||window.document).documentElement}function C(e){return"html"===d(e)?e:e.assignedSlot||e.parentNode||(y(e)?e.host:null)||x(e)}function L(e){return g(e)&&"fixed"!==A(e).position?e.offsetParent:null}function j(e){for(var t=h(e),n=L(e);n&&k(n)&&"static"===A(n).position;)n=L(n);return n&&("html"===d(n)||"body"===d(n)&&"static"===A(n).position)?t:n||function(e){var t=-1!==navigator.userAgent.toLowerCase().indexOf("firefox");if(-1!==navigator.userAgent.indexOf("Trident")&&g(e)&&"fixed"===A(e).position)return null;for(var n=C(e);g(n)&&["html","body"].indexOf(d(n))<0;){var r=A(n);if("none"!==r.transform||"none"!==r.perspective||"paint"===r.contain||-1!==["transform","perspective"].indexOf(r.willChange)||t&&"filter"===r.willChange||t&&r.filter&&"none"!==r.filter)return n;n=n.parentNode}return null}(e)||t}function P(e){return["top","bottom"].indexOf(e)>=0?"x":"y"}var M=Math.max,B=Math.min,S=Math.round;function _(e,t,n){return M(e,B(t,n))}function D(e){return Object.assign({},{top:0,right:0,bottom:0,left:0},e)}function N(e,t){return t.reduce((function(t,n){return t[n]=e,t}),{})}var V={top:"auto",right:"auto",bottom:"auto",left:"auto"};function I(i){var o,s=i.popper,a=i.popperRect,c=i.placement,u=i.offsets,l=i.position,f=i.gpuAcceleration,p=i.adaptive,d=i.roundOffsets,m=!0===d?function(e){var t=e.x,n=e.y,r=window.devicePixelRatio||1;return{x:S(S(t*r)/r)||0,y:S(S(n*r)/r)||0}}(u):"function"==typeof d?d(u):u,g=m.x,y=void 0===g?0:g,v=m.y,b=void 0===v?0:v,w=u.hasOwnProperty("x"),O=u.hasOwnProperty("y"),E=r,T=e,k=window;if(p){var C=j(s),L="clientHeight",P="clientWidth";C===h(s)&&"static"!==A(C=x(s)).position&&(L="scrollHeight",P="scrollWidth"),C=C,c===e&&(T=t,b-=C[L]-a.height,b*=f?1:-1),c===r&&(E=n,y-=C[P]-a.width,y*=f?1:-1)}var M,B=Object.assign({position:l},p&&V);return f?Object.assign({},B,((M={})[T]=O?"0":"",M[E]=w?"0":"",M.transform=(k.devicePixelRatio||1)<2?"translate("+y+"px, "+b+"px)":"translate3d("+y+"px, "+b+"px, 0)",M)):Object.assign({},B,((o={})[T]=O?b+"px":"",o[E]=w?y+"px":"",o.transform="",o))}var F={passive:!0};var R={left:"right",right:"left",bottom:"top",top:"bottom"};function K(e){return e.replace(/left|right|bottom|top/g,(function(e){return R[e]}))}var W={start:"end",end:"start"};function U(e){return e.replace(/start|end/g,(function(e){return W[e]}))}function H(e){var t=h(e);return{scrollLeft:t.pageXOffset,scrollTop:t.pageYOffset}}function q(e){return O(x(e)).left+H(e).scrollLeft}function z(e){var t=A(e),n=t.overflow,r=t.overflowX,i=t.overflowY;return/auto|scroll|overlay|hidden/.test(n+i+r)}function $(e){return["html","body","#document"].indexOf(d(e))>=0?e.ownerDocument.body:g(e)&&z(e)?e:$(C(e))}function Y(e,t){var n;void 0===t&&(t=[]);var r=$(e),i=r===(null==(n=e.ownerDocument)?void 0:n.body),o=h(r),s=i?[o].concat(o.visualViewport||[],z(r)?r:[]):r,a=t.concat(s);return i?a:a.concat(Y(C(s)))}function J(e){return Object.assign({},e,{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}function X(e,t){return t===c?J(function(e){var t=h(e),n=x(e),r=t.visualViewport,i=n.clientWidth,o=n.clientHeight,s=0,a=0;return r&&(i=r.width,o=r.height,/^((?!chrome|android).)*safari/i.test(navigator.userAgent)||(s=r.offsetLeft,a=r.offsetTop)),{width:i,height:o,x:s+q(e),y:a}}(e)):g(t)?function(e){var t=O(e);return t.top=t.top+e.clientTop,t.left=t.left+e.clientLeft,t.bottom=t.top+e.clientHeight,t.right=t.left+e.clientWidth,t.width=e.clientWidth,t.height=e.clientHeight,t.x=t.left,t.y=t.top,t}(t):J(function(e){var t,n=x(e),r=H(e),i=null==(t=e.ownerDocument)?void 0:t.body,o=M(n.scrollWidth,n.clientWidth,i?i.scrollWidth:0,i?i.clientWidth:0),s=M(n.scrollHeight,n.clientHeight,i?i.scrollHeight:0,i?i.clientHeight:0),a=-r.scrollLeft+q(e),c=-r.scrollTop;return"rtl"===A(i||n).direction&&(a+=M(n.clientWidth,i?i.clientWidth:0)-o),{width:o,height:s,x:a,y:c}}(x(e)))}function Q(e,t,n){var r="clippingParents"===t?function(e){var t=Y(C(e)),n=["absolute","fixed"].indexOf(A(e).position)>=0&&g(e)?j(e):e;return m(n)?t.filter((function(e){return m(e)&&T(e,n)&&"body"!==d(e)})):[]}(e):[].concat(t),i=[].concat(r,[n]),o=i[0],s=i.reduce((function(t,n){var r=X(e,n);return t.top=M(r.top,t.top),t.right=B(r.right,t.right),t.bottom=B(r.bottom,t.bottom),t.left=M(r.left,t.left),t}),X(e,o));return s.width=s.right-s.left,s.height=s.bottom-s.top,s.x=s.left,s.y=s.top,s}function G(e){return e.split("-")[1]}function Z(i){var o,c=i.reference,u=i.element,l=i.placement,f=l?b(l):null,p=l?G(l):null,d=c.x+c.width/2-u.width/2,h=c.y+c.height/2-u.height/2;switch(f){case e:o={x:d,y:c.y-u.height};break;case t:o={x:d,y:c.y+c.height};break;case n:o={x:c.x+c.width,y:h};break;case r:o={x:c.x-u.width,y:h};break;default:o={x:c.x,y:c.y}}var m=f?P(f):null;if(null!=m){var g="y"===m?"height":"width";switch(p){case s:o[m]=o[m]-(c[g]/2-u[g]/2);break;case a:o[m]=o[m]+(c[g]/2-u[g]/2)}}return o}function ee(r,i){void 0===i&&(i={});var s=i,a=s.placement,l=void 0===a?r.placement:a,f=s.boundary,p=void 0===f?"clippingParents":f,d=s.rootBoundary,h=void 0===d?c:d,g=s.elementContext,y=void 0===g?u:g,v=s.altBoundary,b=void 0!==v&&v,w=s.padding,E=void 0===w?0:w,T=D("number"!=typeof E?E:N(E,o)),A=y===u?"reference":u,k=r.elements.reference,C=r.rects.popper,L=r.elements[b?A:y],j=Q(m(L)?L:L.contextElement||x(r.elements.popper),p,h),P=O(k),M=Z({reference:P,element:C,strategy:"absolute",placement:l}),B=J(Object.assign({},C,M)),S=y===u?B:P,_={top:j.top-S.top+T.top,bottom:S.bottom-j.bottom+T.bottom,left:j.left-S.left+T.left,right:S.right-j.right+T.right},V=r.modifiersData.offset;if(y===u&&V){var I=V[l];Object.keys(_).forEach((function(r){var i=[n,t].indexOf(r)>=0?1:-1,o=[e,t].indexOf(r)>=0?"y":"x";_[r]+=I[o]*i}))}return _}function te(e,t){void 0===t&&(t={});var n=t,r=n.placement,i=n.boundary,s=n.rootBoundary,a=n.padding,c=n.flipVariations,u=n.allowedAutoPlacements,p=void 0===u?f:u,d=G(r),h=d?c?l:l.filter((function(e){return G(e)===d})):o,m=h.filter((function(e){return p.indexOf(e)>=0}));0===m.length&&(m=h);var g=m.reduce((function(t,n){return t[n]=ee(e,{placement:n,boundary:i,rootBoundary:s,padding:a})[b(n)],t}),{});return Object.keys(g).sort((function(e,t){return g[e]-g[t]}))}function ne(e,t,n){return void 0===n&&(n={x:0,y:0}),{top:e.top-t.height-n.y,right:e.right-t.width+n.x,bottom:e.bottom-t.height+n.y,left:e.left-t.width-n.x}}function re(i){return[e,n,t,r].some((function(e){return i[e]>=0}))}function ie(e,t,n){void 0===n&&(n=!1);var r,i,o=g(t),s=g(t)&&function(e){var t=e.getBoundingClientRect(),n=t.width/e.offsetWidth||1,r=t.height/e.offsetHeight||1;return 1!==n||1!==r}(t),a=x(t),c=O(e,s),u={scrollLeft:0,scrollTop:0},l={x:0,y:0};return(o||!o&&!n)&&(("body"!==d(t)||z(a))&&(u=(r=t)!==h(r)&&g(r)?{scrollLeft:(i=r).scrollLeft,scrollTop:i.scrollTop}:H(r)),g(t)?((l=O(t,!0)).x+=t.clientLeft,l.y+=t.clientTop):a&&(l.x=q(a))),{x:c.left+u.scrollLeft-l.x,y:c.top+u.scrollTop-l.y,width:c.width,height:c.height}}function oe(e){var t=new Map,n=new Set,r=[];function i(e){n.add(e.name),[].concat(e.requires||[],e.requiresIfExists||[]).forEach((function(e){if(!n.has(e)){var r=t.get(e);r&&i(r)}})),r.push(e)}return e.forEach((function(e){t.set(e.name,e)})),e.forEach((function(e){n.has(e.name)||i(e)})),r}var se={placement:"bottom",modifiers:[],strategy:"absolute"};function ae(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return!t.some((function(e){return!(e&&"function"==typeof e.getBoundingClientRect)}))}function ce(e){void 0===e&&(e={});var t=e,n=t.defaultModifiers,r=void 0===n?[]:n,i=t.defaultOptions,o=void 0===i?se:i;return function(e,t,n){void 0===n&&(n=o);var i,s,a={placement:"bottom",orderedModifiers:[],options:Object.assign({},se,o),modifiersData:{},elements:{reference:e,popper:t},attributes:{},styles:{}},c=[],u=!1,l={state:a,setOptions:function(n){f(),a.options=Object.assign({},o,a.options,n),a.scrollParents={reference:m(e)?Y(e):e.contextElement?Y(e.contextElement):[],popper:Y(t)};var i,s,u=function(e){var t=oe(e);return p.reduce((function(e,n){return e.concat(t.filter((function(e){return e.phase===n})))}),[])}((i=[].concat(r,a.options.modifiers),s=i.reduce((function(e,t){var n=e[t.name];return e[t.name]=n?Object.assign({},n,t,{options:Object.assign({},n.options,t.options),data:Object.assign({},n.data,t.data)}):t,e}),{}),Object.keys(s).map((function(e){return s[e]}))));return a.orderedModifiers=u.filter((function(e){return e.enabled})),a.orderedModifiers.forEach((function(e){var t=e.name,n=e.options,r=void 0===n?{}:n,i=e.effect;if("function"==typeof i){var o=i({state:a,name:t,instance:l,options:r}),s=function(){};c.push(o||s)}})),l.update()},forceUpdate:function(){if(!u){var e=a.elements,t=e.reference,n=e.popper;if(ae(t,n)){a.rects={reference:ie(t,j(n),"fixed"===a.options.strategy),popper:E(n)},a.reset=!1,a.placement=a.options.placement,a.orderedModifiers.forEach((function(e){return a.modifiersData[e.name]=Object.assign({},e.data)}));for(var r=0;r<a.orderedModifiers.length;r++)if(!0!==a.reset){var i=a.orderedModifiers[r],o=i.fn,s=i.options,c=void 0===s?{}:s,f=i.name;"function"==typeof o&&(a=o({state:a,options:c,name:f,instance:l})||a)}else a.reset=!1,r=-1}}},update:(i=function(){return new Promise((function(e){l.forceUpdate(),e(a)}))},function(){return s||(s=new Promise((function(e){Promise.resolve().then((function(){s=void 0,e(i())}))}))),s}),destroy:function(){f(),u=!0}};if(!ae(e,t))return l;function f(){c.forEach((function(e){return e()})),c=[]}return l.setOptions(n).then((function(e){!u&&n.onFirstUpdate&&n.onFirstUpdate(e)})),l}}var ue=ce({defaultModifiers:[{name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:function(e){var t=e.state,n=e.instance,r=e.options,i=r.scroll,o=void 0===i||i,s=r.resize,a=void 0===s||s,c=h(t.elements.popper),u=[].concat(t.scrollParents.reference,t.scrollParents.popper);return o&&u.forEach((function(e){e.addEventListener("scroll",n.update,F)})),a&&c.addEventListener("resize",n.update,F),function(){o&&u.forEach((function(e){e.removeEventListener("scroll",n.update,F)})),a&&c.removeEventListener("resize",n.update,F)}},data:{}},{name:"popperOffsets",enabled:!0,phase:"read",fn:function(e){var t=e.state,n=e.name;t.modifiersData[n]=Z({reference:t.rects.reference,element:t.rects.popper,strategy:"absolute",placement:t.placement})},data:{}},{name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:function(e){var t=e.state,n=e.options,r=n.gpuAcceleration,i=void 0===r||r,o=n.adaptive,s=void 0===o||o,a=n.roundOffsets,c=void 0===a||a,u={placement:b(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:i};null!=t.modifiersData.popperOffsets&&(t.styles.popper=Object.assign({},t.styles.popper,I(Object.assign({},u,{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:s,roundOffsets:c})))),null!=t.modifiersData.arrow&&(t.styles.arrow=Object.assign({},t.styles.arrow,I(Object.assign({},u,{offsets:t.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:c})))),t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-placement":t.placement})},data:{}},v,{name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:function(t){var i=t.state,o=t.options,s=t.name,a=o.offset,c=void 0===a?[0,0]:a,u=f.reduce((function(t,o){return t[o]=function(t,i,o){var s=b(t),a=[r,e].indexOf(s)>=0?-1:1,c="function"==typeof o?o(Object.assign({},i,{placement:t})):o,u=c[0],l=c[1];return u=u||0,l=(l||0)*a,[r,n].indexOf(s)>=0?{x:l,y:u}:{x:u,y:l}}(o,i.rects,c),t}),{}),l=u[i.placement],p=l.x,d=l.y;null!=i.modifiersData.popperOffsets&&(i.modifiersData.popperOffsets.x+=p,i.modifiersData.popperOffsets.y+=d),i.modifiersData[s]=u}},{name:"flip",enabled:!0,phase:"main",fn:function(o){var a=o.state,c=o.options,u=o.name;if(!a.modifiersData[u]._skip){for(var l=c.mainAxis,f=void 0===l||l,p=c.altAxis,d=void 0===p||p,h=c.fallbackPlacements,m=c.padding,g=c.boundary,y=c.rootBoundary,v=c.altBoundary,w=c.flipVariations,O=void 0===w||w,E=c.allowedAutoPlacements,T=a.options.placement,A=b(T),k=h||(A===T||!O?[K(T)]:function(e){if(b(e)===i)return[];var t=K(e);return[U(e),t,U(t)]}(T)),x=[T].concat(k).reduce((function(e,t){return e.concat(b(t)===i?te(a,{placement:t,boundary:g,rootBoundary:y,padding:m,flipVariations:O,allowedAutoPlacements:E}):t)}),[]),C=a.rects.reference,L=a.rects.popper,j=new Map,P=!0,M=x[0],B=0;B<x.length;B++){var S=x[B],_=b(S),D=G(S)===s,N=[e,t].indexOf(_)>=0,V=N?"width":"height",I=ee(a,{placement:S,boundary:g,rootBoundary:y,altBoundary:v,padding:m}),F=N?D?n:r:D?t:e;C[V]>L[V]&&(F=K(F));var R=K(F),W=[];if(f&&W.push(I[_]<=0),d&&W.push(I[F]<=0,I[R]<=0),W.every((function(e){return e}))){M=S,P=!1;break}j.set(S,W)}if(P)for(var H=function(e){var t=x.find((function(t){var n=j.get(t);if(n)return n.slice(0,e).every((function(e){return e}))}));if(t)return M=t,"break"},q=O?3:1;q>0;q--){if("break"===H(q))break}a.placement!==M&&(a.modifiersData[u]._skip=!0,a.placement=M,a.reset=!0)}},requiresIfExists:["offset"],data:{_skip:!1}},{name:"preventOverflow",enabled:!0,phase:"main",fn:function(i){var o=i.state,a=i.options,c=i.name,u=a.mainAxis,l=void 0===u||u,f=a.altAxis,p=void 0!==f&&f,d=a.boundary,h=a.rootBoundary,m=a.altBoundary,g=a.padding,y=a.tether,v=void 0===y||y,w=a.tetherOffset,O=void 0===w?0:w,T=ee(o,{boundary:d,rootBoundary:h,padding:g,altBoundary:m}),A=b(o.placement),k=G(o.placement),x=!k,C=P(A),L="x"===C?"y":"x",S=o.modifiersData.popperOffsets,D=o.rects.reference,N=o.rects.popper,V="function"==typeof O?O(Object.assign({},o.rects,{placement:o.placement})):O,I={x:0,y:0};if(S){if(l||p){var F="y"===C?e:r,R="y"===C?t:n,K="y"===C?"height":"width",W=S[C],U=S[C]+T[F],H=S[C]-T[R],q=v?-N[K]/2:0,z=k===s?D[K]:N[K],$=k===s?-N[K]:-D[K],Y=o.elements.arrow,J=v&&Y?E(Y):{width:0,height:0},X=o.modifiersData["arrow#persistent"]?o.modifiersData["arrow#persistent"].padding:{top:0,right:0,bottom:0,left:0},Q=X[F],Z=X[R],te=_(0,D[K],J[K]),ne=x?D[K]/2-q-te-Q-V:z-te-Q-V,re=x?-D[K]/2+q+te+Z+V:$+te+Z+V,ie=o.elements.arrow&&j(o.elements.arrow),oe=ie?"y"===C?ie.clientTop||0:ie.clientLeft||0:0,se=o.modifiersData.offset?o.modifiersData.offset[o.placement][C]:0,ae=S[C]+ne-se-oe,ce=S[C]+re-se;if(l){var ue=_(v?B(U,ae):U,W,v?M(H,ce):H);S[C]=ue,I[C]=ue-W}if(p){var le="x"===C?e:r,fe="x"===C?t:n,pe=S[L],de=pe+T[le],he=pe-T[fe],me=_(v?B(de,ae):de,pe,v?M(he,ce):he);S[L]=me,I[L]=me-pe}}o.modifiersData[c]=I}},requiresIfExists:["offset"]},{name:"arrow",enabled:!0,phase:"main",fn:function(i){var s,a=i.state,c=i.name,u=i.options,l=a.elements.arrow,f=a.modifiersData.popperOffsets,p=b(a.placement),d=P(p),h=[r,n].indexOf(p)>=0?"height":"width";if(l&&f){var m=function(e,t){return D("number"!=typeof(e="function"==typeof e?e(Object.assign({},t.rects,{placement:t.placement})):e)?e:N(e,o))}(u.padding,a),g=E(l),y="y"===d?e:r,v="y"===d?t:n,w=a.rects.reference[h]+a.rects.reference[d]-f[d]-a.rects.popper[h],O=f[d]-a.rects.reference[d],T=j(l),A=T?"y"===d?T.clientHeight||0:T.clientWidth||0:0,k=w/2-O/2,x=m[y],C=A-g[h]-m[v],L=A/2-g[h]/2+k,M=_(x,L,C),B=d;a.modifiersData[c]=((s={})[B]=M,s.centerOffset=M-L,s)}},effect:function(e){var t=e.state,n=e.options.element,r=void 0===n?"[data-popper-arrow]":n;null!=r&&("string"!=typeof r||(r=t.elements.popper.querySelector(r)))&&T(t.elements.popper,r)&&(t.elements.arrow=r)},requires:["popperOffsets"],requiresIfExists:["preventOverflow"]},{name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:function(e){var t=e.state,n=e.name,r=t.rects.reference,i=t.rects.popper,o=t.modifiersData.preventOverflow,s=ee(t,{elementContext:"reference"}),a=ee(t,{altBoundary:!0}),c=ne(s,r),u=ne(a,i,o),l=re(c),f=re(u);t.modifiersData[n]={referenceClippingOffsets:c,popperEscapeOffsets:u,isReferenceHidden:l,hasPopperEscaped:f},t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-reference-hidden":l,"data-popper-escaped":f})}}]}),le="tippy-content",fe="tippy-arrow",pe="tippy-svg-arrow",de={passive:!0,capture:!0};function he(e,t,n){if(Array.isArray(e)){var r=e[t];return null==r?Array.isArray(n)?n[t]:n:r}return e}function me(e,t){var n={}.toString.call(e);return 0===n.indexOf("[object")&&n.indexOf(t+"]")>-1}function ge(e,t){return"function"==typeof e?e.apply(void 0,t):e}function ye(e,t){return 0===t?e:function(r){clearTimeout(n),n=setTimeout((function(){e(r)}),t)};var n}function ve(e){return[].concat(e)}function be(e,t){-1===e.indexOf(t)&&e.push(t)}function we(e){return[].slice.call(e)}function Oe(){return document.createElement("div")}function Ee(e){return["Element","Fragment"].some((function(t){return me(e,t)}))}function Te(e){return Ee(e)?[e]:function(e){return me(e,"NodeList")}(e)?we(e):Array.isArray(e)?e:we(document.querySelectorAll(e))}function Ae(e,t){e.forEach((function(e){e&&(e.style.transitionDuration=t+"ms")}))}function ke(e,t){e.forEach((function(e){e&&e.setAttribute("data-state",t)}))}function xe(e,t,n){var r=t+"EventListener";["transitionend","webkitTransitionEnd"].forEach((function(t){e[r](t,n)}))}var Ce={isTouch:!1},Le=0;function je(){Ce.isTouch||(Ce.isTouch=!0,window.performance&&document.addEventListener("mousemove",Pe))}function Pe(){var e=performance.now();e-Le<20&&(Ce.isTouch=!1,document.removeEventListener("mousemove",Pe)),Le=e}function Me(){var e,t=document.activeElement;if((e=t)&&e._tippy&&e._tippy.reference===e){var n=t._tippy;t.blur&&!n.state.isVisible&&t.blur()}}var Be="undefined"!=typeof window&&"undefined"!=typeof document?navigator.userAgent:"",Se=/MSIE |Trident\//.test(Be),_e=Object.assign({appendTo:function(){return document.body},aria:{content:"auto",expanded:"auto"},delay:0,duration:[300,250],getReferenceClientRect:null,hideOnClick:!0,ignoreAttributes:!1,interactive:!1,interactiveBorder:2,interactiveDebounce:0,moveTransition:"",offset:[0,10],onAfterUpdate:function(){},onBeforeUpdate:function(){},onCreate:function(){},onDestroy:function(){},onHidden:function(){},onHide:function(){},onMount:function(){},onShow:function(){},onShown:function(){},onTrigger:function(){},onUntrigger:function(){},onClickOutside:function(){},placement:"top",plugins:[],popperOptions:{},render:null,showOnCreate:!1,touch:!0,trigger:"mouseenter focus",triggerTarget:null},{animateFill:!1,followCursor:!1,inlinePositioning:!1,sticky:!1},{},{allowHTML:!1,animation:"fade",arrow:!0,content:"",inertia:!1,maxWidth:350,role:"tooltip",theme:"",zIndex:9999}),De=Object.keys(_e);function Ne(e){var t=(e.plugins||[]).reduce((function(t,n){var r=n.name,i=n.defaultValue;return r&&(t[r]=void 0!==e[r]?e[r]:i),t}),{});return Object.assign({},e,{},t)}function Ve(e,t){var n=Object.assign({},t,{content:ge(t.content,[e])},t.ignoreAttributes?{}:function(e,t){return(t?Object.keys(Ne(Object.assign({},_e,{plugins:t}))):De).reduce((function(t,n){var r=(e.getAttribute("data-tippy-"+n)||"").trim();if(!r)return t;if("content"===n)t[n]=r;else try{t[n]=JSON.parse(r)}catch(e){t[n]=r}return t}),{})}(e,t.plugins));return n.aria=Object.assign({},_e.aria,{},n.aria),n.aria={expanded:"auto"===n.aria.expanded?t.interactive:n.aria.expanded,content:"auto"===n.aria.content?t.interactive?null:"describedby":n.aria.content},n}function Ie(e,t){e.innerHTML=t}function Fe(e){var t=Oe();return!0===e?t.className=fe:(t.className=pe,Ee(e)?t.appendChild(e):Ie(t,e)),t}function Re(e,t){Ee(t.content)?(Ie(e,""),e.appendChild(t.content)):"function"!=typeof t.content&&(t.allowHTML?Ie(e,t.content):e.textContent=t.content)}function Ke(e){var t=e.firstElementChild,n=we(t.children);return{box:t,content:n.find((function(e){return e.classList.contains(le)})),arrow:n.find((function(e){return e.classList.contains(fe)||e.classList.contains(pe)})),backdrop:n.find((function(e){return e.classList.contains("tippy-backdrop")}))}}function We(e){var t=Oe(),n=Oe();n.className="tippy-box",n.setAttribute("data-state","hidden"),n.setAttribute("tabindex","-1");var r=Oe();function i(n,r){var i=Ke(t),o=i.box,s=i.content,a=i.arrow;r.theme?o.setAttribute("data-theme",r.theme):o.removeAttribute("data-theme"),"string"==typeof r.animation?o.setAttribute("data-animation",r.animation):o.removeAttribute("data-animation"),r.inertia?o.setAttribute("data-inertia",""):o.removeAttribute("data-inertia"),o.style.maxWidth="number"==typeof r.maxWidth?r.maxWidth+"px":r.maxWidth,r.role?o.setAttribute("role",r.role):o.removeAttribute("role"),n.content===r.content&&n.allowHTML===r.allowHTML||Re(s,e.props),r.arrow?a?n.arrow!==r.arrow&&(o.removeChild(a),o.appendChild(Fe(r.arrow))):o.appendChild(Fe(r.arrow)):a&&o.removeChild(a)}return r.className=le,r.setAttribute("data-state","hidden"),Re(r,e.props),t.appendChild(n),n.appendChild(r),i(e.props,e.props),{popper:t,onUpdate:i}}We.$$tippy=!0;var Ue=1,He=[],qe=[];function ze(e,t){var n,r,i,o,s,a,c,u,l,f=Ve(e,Object.assign({},_e,{},Ne((n=t,Object.keys(n).reduce((function(e,t){return void 0!==n[t]&&(e[t]=n[t]),e}),{}))))),p=!1,d=!1,h=!1,m=!1,g=[],y=ye(Y,f.interactiveDebounce),v=Ue++,b=(l=f.plugins).filter((function(e,t){return l.indexOf(e)===t})),w={id:v,reference:e,popper:Oe(),popperInstance:null,props:f,state:{isEnabled:!0,isVisible:!1,isDestroyed:!1,isMounted:!1,isShown:!1},plugins:b,clearDelayTimeouts:function(){clearTimeout(r),clearTimeout(i),cancelAnimationFrame(o)},setProps:function(t){if(w.state.isDestroyed)return;_("onBeforeUpdate",[w,t]),z();var n=w.props,r=Ve(e,Object.assign({},w.props,{},t,{ignoreAttributes:!0}));w.props=r,q(),n.interactiveDebounce!==r.interactiveDebounce&&(V(),y=ye(Y,r.interactiveDebounce));n.triggerTarget&&!r.triggerTarget?ve(n.triggerTarget).forEach((function(e){e.removeAttribute("aria-expanded")})):r.triggerTarget&&e.removeAttribute("aria-expanded");N(),S(),T&&T(n,r);w.popperInstance&&(G(),ee().forEach((function(e){requestAnimationFrame(e._tippy.popperInstance.forceUpdate)})));_("onAfterUpdate",[w,t])},setContent:function(e){w.setProps({content:e})},show:function(){var e=w.state.isVisible,t=w.state.isDestroyed,n=!w.state.isEnabled,r=Ce.isTouch&&!w.props.touch,i=he(w.props.duration,0,_e.duration);if(e||t||n||r)return;if(j().hasAttribute("disabled"))return;if(_("onShow",[w],!1),!1===w.props.onShow(w))return;w.state.isVisible=!0,L()&&(E.style.visibility="visible");S(),K(),w.state.isMounted||(E.style.transition="none");if(L()){var o=M(),s=o.box,a=o.content;Ae([s,a],0)}c=function(){var e;if(w.state.isVisible&&!m){if(m=!0,E.offsetHeight,E.style.transition=w.props.moveTransition,L()&&w.props.animation){var t=M(),n=t.box,r=t.content;Ae([n,r],i),ke([n,r],"visible")}D(),N(),be(qe,w),null==(e=w.popperInstance)||e.forceUpdate(),w.state.isMounted=!0,_("onMount",[w]),w.props.animation&&L()&&function(e,t){U(e,t)}(i,(function(){w.state.isShown=!0,_("onShown",[w])}))}},function(){var e,t=w.props.appendTo,n=j();e=w.props.interactive&&t===_e.appendTo||"parent"===t?n.parentNode:ge(t,[n]);e.contains(E)||e.appendChild(E);G()}()},hide:function(){var e=!w.state.isVisible,t=w.state.isDestroyed,n=!w.state.isEnabled,r=he(w.props.duration,1,_e.duration);if(e||t||n)return;if(_("onHide",[w],!1),!1===w.props.onHide(w))return;w.state.isVisible=!1,w.state.isShown=!1,m=!1,p=!1,L()&&(E.style.visibility="hidden");if(V(),W(),S(),L()){var i=M(),o=i.box,s=i.content;w.props.animation&&(Ae([o,s],r),ke([o,s],"hidden"))}D(),N(),w.props.animation?L()&&function(e,t){U(e,(function(){!w.state.isVisible&&E.parentNode&&E.parentNode.contains(E)&&t()}))}(r,w.unmount):w.unmount()},hideWithInteractivity:function(e){P().addEventListener("mousemove",y),be(He,y),y(e)},enable:function(){w.state.isEnabled=!0},disable:function(){w.hide(),w.state.isEnabled=!1},unmount:function(){w.state.isVisible&&w.hide();if(!w.state.isMounted)return;Z(),ee().forEach((function(e){e._tippy.unmount()})),E.parentNode&&E.parentNode.removeChild(E);qe=qe.filter((function(e){return e!==w})),w.state.isMounted=!1,_("onHidden",[w])},destroy:function(){if(w.state.isDestroyed)return;w.clearDelayTimeouts(),w.unmount(),z(),delete e._tippy,w.state.isDestroyed=!0,_("onDestroy",[w])}};if(!f.render)return w;var O=f.render(w),E=O.popper,T=O.onUpdate;E.setAttribute("data-tippy-root",""),E.id="tippy-"+w.id,w.popper=E,e._tippy=w,E._tippy=w;var A=b.map((function(e){return e.fn(w)})),k=e.hasAttribute("aria-expanded");return q(),N(),S(),_("onCreate",[w]),f.showOnCreate&&te(),E.addEventListener("mouseenter",(function(){w.props.interactive&&w.state.isVisible&&w.clearDelayTimeouts()})),E.addEventListener("mouseleave",(function(e){w.props.interactive&&w.props.trigger.indexOf("mouseenter")>=0&&(P().addEventListener("mousemove",y),y(e))})),w;function x(){var e=w.props.touch;return Array.isArray(e)?e:[e,0]}function C(){return"hold"===x()[0]}function L(){var e;return!!(null==(e=w.props.render)?void 0:e.$$tippy)}function j(){return u||e}function P(){var e,t,n=j().parentNode;return n?(null==(t=ve(n)[0])||null==(e=t.ownerDocument)?void 0:e.body)?t.ownerDocument:document:document}function M(){return Ke(E)}function B(e){return w.state.isMounted&&!w.state.isVisible||Ce.isTouch||s&&"focus"===s.type?0:he(w.props.delay,e?0:1,_e.delay)}function S(){E.style.pointerEvents=w.props.interactive&&w.state.isVisible?"":"none",E.style.zIndex=""+w.props.zIndex}function _(e,t,n){var r;(void 0===n&&(n=!0),A.forEach((function(n){n[e]&&n[e].apply(void 0,t)})),n)&&(r=w.props)[e].apply(r,t)}function D(){var t=w.props.aria;if(t.content){var n="aria-"+t.content,r=E.id;ve(w.props.triggerTarget||e).forEach((function(e){var t=e.getAttribute(n);if(w.state.isVisible)e.setAttribute(n,t?t+" "+r:r);else{var i=t&&t.replace(r,"").trim();i?e.setAttribute(n,i):e.removeAttribute(n)}}))}}function N(){!k&&w.props.aria.expanded&&ve(w.props.triggerTarget||e).forEach((function(e){w.props.interactive?e.setAttribute("aria-expanded",w.state.isVisible&&e===j()?"true":"false"):e.removeAttribute("aria-expanded")}))}function V(){P().removeEventListener("mousemove",y),He=He.filter((function(e){return e!==y}))}function I(e){if(!(Ce.isTouch&&(h||"mousedown"===e.type)||w.props.interactive&&E.contains(e.target))){if(j().contains(e.target)){if(Ce.isTouch)return;if(w.state.isVisible&&w.props.trigger.indexOf("click")>=0)return}else _("onClickOutside",[w,e]);!0===w.props.hideOnClick&&(w.clearDelayTimeouts(),w.hide(),d=!0,setTimeout((function(){d=!1})),w.state.isMounted||W())}}function F(){h=!0}function R(){h=!1}function K(){var e=P();e.addEventListener("mousedown",I,!0),e.addEventListener("touchend",I,de),e.addEventListener("touchstart",R,de),e.addEventListener("touchmove",F,de)}function W(){var e=P();e.removeEventListener("mousedown",I,!0),e.removeEventListener("touchend",I,de),e.removeEventListener("touchstart",R,de),e.removeEventListener("touchmove",F,de)}function U(e,t){var n=M().box;function r(e){e.target===n&&(xe(n,"remove",r),t())}if(0===e)return t();xe(n,"remove",a),xe(n,"add",r),a=r}function H(t,n,r){void 0===r&&(r=!1),ve(w.props.triggerTarget||e).forEach((function(e){e.addEventListener(t,n,r),g.push({node:e,eventType:t,handler:n,options:r})}))}function q(){var e;C()&&(H("touchstart",$,{passive:!0}),H("touchend",J,{passive:!0})),(e=w.props.trigger,e.split(/\s+/).filter(Boolean)).forEach((function(e){if("manual"!==e)switch(H(e,$),e){case"mouseenter":H("mouseleave",J);break;case"focus":H(Se?"focusout":"blur",X);break;case"focusin":H("focusout",X)}}))}function z(){g.forEach((function(e){var t=e.node,n=e.eventType,r=e.handler,i=e.options;t.removeEventListener(n,r,i)})),g=[]}function $(e){var t,n=!1;if(w.state.isEnabled&&!Q(e)&&!d){var r="focus"===(null==(t=s)?void 0:t.type);s=e,u=e.currentTarget,N(),!w.state.isVisible&&me(e,"MouseEvent")&&He.forEach((function(t){return t(e)})),"click"===e.type&&(w.props.trigger.indexOf("mouseenter")<0||p)&&!1!==w.props.hideOnClick&&w.state.isVisible?n=!0:te(e),"click"===e.type&&(p=!n),n&&!r&&ne(e)}}function Y(e){var t=e.target,n=j().contains(t)||E.contains(t);"mousemove"===e.type&&n||function(e,t){var n=t.clientX,r=t.clientY;return e.every((function(e){var t=e.popperRect,i=e.popperState,o=e.props.interactiveBorder,s=i.placement.split("-")[0],a=i.modifiersData.offset;if(!a)return!0;var c="bottom"===s?a.top.y:0,u="top"===s?a.bottom.y:0,l="right"===s?a.left.x:0,f="left"===s?a.right.x:0,p=t.top-r+c>o,d=r-t.bottom-u>o,h=t.left-n+l>o,m=n-t.right-f>o;return p||d||h||m}))}(ee().concat(E).map((function(e){var t,n=null==(t=e._tippy.popperInstance)?void 0:t.state;return n?{popperRect:e.getBoundingClientRect(),popperState:n,props:f}:null})).filter(Boolean),e)&&(V(),ne(e))}function J(e){Q(e)||w.props.trigger.indexOf("click")>=0&&p||(w.props.interactive?w.hideWithInteractivity(e):ne(e))}function X(e){w.props.trigger.indexOf("focusin")<0&&e.target!==j()||w.props.interactive&&e.relatedTarget&&E.contains(e.relatedTarget)||ne(e)}function Q(e){return!!Ce.isTouch&&C()!==e.type.indexOf("touch")>=0}function G(){Z();var t=w.props,n=t.popperOptions,r=t.placement,i=t.offset,o=t.getReferenceClientRect,s=t.moveTransition,a=L()?Ke(E).arrow:null,u=o?{getBoundingClientRect:o,contextElement:o.contextElement||j()}:e,l=[{name:"offset",options:{offset:i}},{name:"preventOverflow",options:{padding:{top:2,bottom:2,left:5,right:5}}},{name:"flip",options:{padding:5}},{name:"computeStyles",options:{adaptive:!s}},{name:"$$tippy",enabled:!0,phase:"beforeWrite",requires:["computeStyles"],fn:function(e){var t=e.state;if(L()){var n=M().box;["placement","reference-hidden","escaped"].forEach((function(e){"placement"===e?n.setAttribute("data-placement",t.placement):t.attributes.popper["data-popper-"+e]?n.setAttribute("data-"+e,""):n.removeAttribute("data-"+e)})),t.attributes.popper={}}}}];L()&&a&&l.push({name:"arrow",options:{element:a,padding:3}}),l.push.apply(l,(null==n?void 0:n.modifiers)||[]),w.popperInstance=ue(u,E,Object.assign({},n,{placement:r,onFirstUpdate:c,modifiers:l}))}function Z(){w.popperInstance&&(w.popperInstance.destroy(),w.popperInstance=null)}function ee(){return we(E.querySelectorAll("[data-tippy-root]"))}function te(e){w.clearDelayTimeouts(),e&&_("onTrigger",[w,e]),K();var t=B(!0),n=x(),i=n[0],o=n[1];Ce.isTouch&&"hold"===i&&o&&(t=o),t?r=setTimeout((function(){w.show()}),t):w.show()}function ne(e){if(w.clearDelayTimeouts(),_("onUntrigger",[w,e]),w.state.isVisible){if(!(w.props.trigger.indexOf("mouseenter")>=0&&w.props.trigger.indexOf("click")>=0&&["mouseleave","mousemove"].indexOf(e.type)>=0&&p)){var t=B(!1);t?i=setTimeout((function(){w.state.isVisible&&w.hide()}),t):o=requestAnimationFrame((function(){w.hide()}))}}else W()}}function $e(e,t){void 0===t&&(t={});var n=_e.plugins.concat(t.plugins||[]);document.addEventListener("touchstart",je,de),window.addEventListener("blur",Me);var r=Object.assign({},t,{plugins:n}),i=Te(e).reduce((function(e,t){var n=t&&ze(t,r);return n&&e.push(n),e}),[]);return Ee(e)?i[0]:i}$e.defaultProps=_e,$e.setDefaultProps=function(e){Object.keys(e).forEach((function(t){_e[t]=e[t]}))},$e.currentInput=Ce,Object.assign({},v,{effect:function(e){var t=e.state,n={popper:{position:t.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};Object.assign(t.elements.popper.style,n.popper),t.styles=n,t.elements.arrow&&Object.assign(t.elements.arrow.style,n.arrow)}}),$e.setDefaultProps({render:We});var Ye=function(){function e(e,t,n){this.eventTarget=e,this.eventName=t,this.eventOptions=n,this.unorderedBindings=new Set}return e.prototype.connect=function(){this.eventTarget.addEventListener(this.eventName,this,this.eventOptions)},e.prototype.disconnect=function(){this.eventTarget.removeEventListener(this.eventName,this,this.eventOptions)},e.prototype.bindingConnected=function(e){this.unorderedBindings.add(e)},e.prototype.bindingDisconnected=function(e){this.unorderedBindings.delete(e)},e.prototype.handleEvent=function(e){for(var t=function(e){if("immediatePropagationStopped"in e)return e;var t=e.stopImmediatePropagation;return Object.assign(e,{immediatePropagationStopped:!1,stopImmediatePropagation:function(){this.immediatePropagationStopped=!0,t.call(this)}})}(e),n=0,r=this.bindings;n<r.length;n++){var i=r[n];if(t.immediatePropagationStopped)break;i.handleEvent(t)}},Object.defineProperty(e.prototype,"bindings",{get:function(){return Array.from(this.unorderedBindings).sort((function(e,t){var n=e.index,r=t.index;return n<r?-1:n>r?1:0}))},enumerable:!1,configurable:!0}),e}();var Je=function(){function e(e){this.application=e,this.eventListenerMaps=new Map,this.started=!1}return e.prototype.start=function(){this.started||(this.started=!0,this.eventListeners.forEach((function(e){return e.connect()})))},e.prototype.stop=function(){this.started&&(this.started=!1,this.eventListeners.forEach((function(e){return e.disconnect()})))},Object.defineProperty(e.prototype,"eventListeners",{get:function(){return Array.from(this.eventListenerMaps.values()).reduce((function(e,t){return e.concat(Array.from(t.values()))}),[])},enumerable:!1,configurable:!0}),e.prototype.bindingConnected=function(e){this.fetchEventListenerForBinding(e).bindingConnected(e)},e.prototype.bindingDisconnected=function(e){this.fetchEventListenerForBinding(e).bindingDisconnected(e)},e.prototype.handleError=function(e,t,n){void 0===n&&(n={}),this.application.handleError(e,"Error "+t,n)},e.prototype.fetchEventListenerForBinding=function(e){var t=e.eventTarget,n=e.eventName,r=e.eventOptions;return this.fetchEventListener(t,n,r)},e.prototype.fetchEventListener=function(e,t,n){var r=this.fetchEventListenerMapForEventTarget(e),i=this.cacheKey(t,n),o=r.get(i);return o||(o=this.createEventListener(e,t,n),r.set(i,o)),o},e.prototype.createEventListener=function(e,t,n){var r=new Ye(e,t,n);return this.started&&r.connect(),r},e.prototype.fetchEventListenerMapForEventTarget=function(e){var t=this.eventListenerMaps.get(e);return t||(t=new Map,this.eventListenerMaps.set(e,t)),t},e.prototype.cacheKey=function(e,t){var n=[e];return Object.keys(t).sort().forEach((function(e){n.push((t[e]?"":"!")+e)})),n.join(":")},e}(),Xe=/^((.+?)(@(window|document))?->)?(.+?)(#([^:]+?))(:(.+))?$/;function Qe(e){return"window"==e?window:"document"==e?document:void 0}var Ge=function(){function e(e,t,n){this.element=e,this.index=t,this.eventTarget=n.eventTarget||e,this.eventName=n.eventName||function(e){var t=e.tagName.toLowerCase();if(t in Ze)return Ze[t](e)}(e)||et("missing event name"),this.eventOptions=n.eventOptions||{},this.identifier=n.identifier||et("missing identifier"),this.methodName=n.methodName||et("missing method name")}return e.forToken=function(e){return new this(e.element,e.index,(t=e.content,{eventTarget:Qe((r=t.trim().match(Xe)||[])[4]),eventName:r[2],eventOptions:r[9]?(n=r[9],n.split(":").reduce((function(e,t){var n;return Object.assign(e,((n={})[t.replace(/^!/,"")]=!/^!/.test(t),n))}),{})):{},identifier:r[5],methodName:r[7]}));var t,n,r},e.prototype.toString=function(){var e=this.eventTargetName?"@"+this.eventTargetName:"";return""+this.eventName+e+"->"+this.identifier+"#"+this.methodName},Object.defineProperty(e.prototype,"eventTargetName",{get:function(){return(e=this.eventTarget)==window?"window":e==document?"document":void 0;var e},enumerable:!1,configurable:!0}),e}(),Ze={a:function(e){return"click"},button:function(e){return"click"},form:function(e){return"submit"},input:function(e){return"submit"==e.getAttribute("type")?"click":"input"},select:function(e){return"change"},textarea:function(e){return"input"}};function et(e){throw new Error(e)}var tt=function(){function e(e,t){this.context=e,this.action=t}return Object.defineProperty(e.prototype,"index",{get:function(){return this.action.index},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"eventTarget",{get:function(){return this.action.eventTarget},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"eventOptions",{get:function(){return this.action.eventOptions},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"identifier",{get:function(){return this.context.identifier},enumerable:!1,configurable:!0}),e.prototype.handleEvent=function(e){this.willBeInvokedByEvent(e)&&this.invokeWithEvent(e)},Object.defineProperty(e.prototype,"eventName",{get:function(){return this.action.eventName},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"method",{get:function(){var e=this.controller[this.methodName];if("function"==typeof e)return e;throw new Error('Action "'+this.action+'" references undefined method "'+this.methodName+'"')},enumerable:!1,configurable:!0}),e.prototype.invokeWithEvent=function(e){try{this.method.call(this.controller,e)}catch(r){var t=this,n={identifier:t.identifier,controller:t.controller,element:t.element,index:t.index,event:e};this.context.handleError(r,'invoking action "'+this.action+'"',n)}},e.prototype.willBeInvokedByEvent=function(e){var t=e.target;return this.element===t||(t instanceof Element&&this.element.contains(t)?this.scope.containsElement(t):this.scope.containsElement(this.action.element))},Object.defineProperty(e.prototype,"controller",{get:function(){return this.context.controller},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"methodName",{get:function(){return this.action.methodName},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"element",{get:function(){return this.scope.element},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"scope",{get:function(){return this.context.scope},enumerable:!1,configurable:!0}),e}(),nt=function(){function e(e,t){var n=this;this.element=e,this.started=!1,this.delegate=t,this.elements=new Set,this.mutationObserver=new MutationObserver((function(e){return n.processMutations(e)}))}return e.prototype.start=function(){this.started||(this.started=!0,this.mutationObserver.observe(this.element,{attributes:!0,childList:!0,subtree:!0}),this.refresh())},e.prototype.stop=function(){this.started&&(this.mutationObserver.takeRecords(),this.mutationObserver.disconnect(),this.started=!1)},e.prototype.refresh=function(){if(this.started){for(var e=new Set(this.matchElementsInTree()),t=0,n=Array.from(this.elements);t<n.length;t++){var r=n[t];e.has(r)||this.removeElement(r)}for(var i=0,o=Array.from(e);i<o.length;i++){r=o[i];this.addElement(r)}}},e.prototype.processMutations=function(e){if(this.started)for(var t=0,n=e;t<n.length;t++){var r=n[t];this.processMutation(r)}},e.prototype.processMutation=function(e){"attributes"==e.type?this.processAttributeChange(e.target,e.attributeName):"childList"==e.type&&(this.processRemovedNodes(e.removedNodes),this.processAddedNodes(e.addedNodes))},e.prototype.processAttributeChange=function(e,t){var n=e;this.elements.has(n)?this.delegate.elementAttributeChanged&&this.matchElement(n)?this.delegate.elementAttributeChanged(n,t):this.removeElement(n):this.matchElement(n)&&this.addElement(n)},e.prototype.processRemovedNodes=function(e){for(var t=0,n=Array.from(e);t<n.length;t++){var r=n[t],i=this.elementFromNode(r);i&&this.processTree(i,this.removeElement)}},e.prototype.processAddedNodes=function(e){for(var t=0,n=Array.from(e);t<n.length;t++){var r=n[t],i=this.elementFromNode(r);i&&this.elementIsActive(i)&&this.processTree(i,this.addElement)}},e.prototype.matchElement=function(e){return this.delegate.matchElement(e)},e.prototype.matchElementsInTree=function(e){return void 0===e&&(e=this.element),this.delegate.matchElementsInTree(e)},e.prototype.processTree=function(e,t){for(var n=0,r=this.matchElementsInTree(e);n<r.length;n++){var i=r[n];t.call(this,i)}},e.prototype.elementFromNode=function(e){if(e.nodeType==Node.ELEMENT_NODE)return e},e.prototype.elementIsActive=function(e){return e.isConnected==this.element.isConnected&&this.element.contains(e)},e.prototype.addElement=function(e){this.elements.has(e)||this.elementIsActive(e)&&(this.elements.add(e),this.delegate.elementMatched&&this.delegate.elementMatched(e))},e.prototype.removeElement=function(e){this.elements.has(e)&&(this.elements.delete(e),this.delegate.elementUnmatched&&this.delegate.elementUnmatched(e))},e}(),rt=function(){function e(e,t,n){this.attributeName=t,this.delegate=n,this.elementObserver=new nt(e,this)}return Object.defineProperty(e.prototype,"element",{get:function(){return this.elementObserver.element},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"selector",{get:function(){return"["+this.attributeName+"]"},enumerable:!1,configurable:!0}),e.prototype.start=function(){this.elementObserver.start()},e.prototype.stop=function(){this.elementObserver.stop()},e.prototype.refresh=function(){this.elementObserver.refresh()},Object.defineProperty(e.prototype,"started",{get:function(){return this.elementObserver.started},enumerable:!1,configurable:!0}),e.prototype.matchElement=function(e){return e.hasAttribute(this.attributeName)},e.prototype.matchElementsInTree=function(e){var t=this.matchElement(e)?[e]:[],n=Array.from(e.querySelectorAll(this.selector));return t.concat(n)},e.prototype.elementMatched=function(e){this.delegate.elementMatchedAttribute&&this.delegate.elementMatchedAttribute(e,this.attributeName)},e.prototype.elementUnmatched=function(e){this.delegate.elementUnmatchedAttribute&&this.delegate.elementUnmatchedAttribute(e,this.attributeName)},e.prototype.elementAttributeChanged=function(e,t){this.delegate.elementAttributeValueChanged&&this.attributeName==t&&this.delegate.elementAttributeValueChanged(e,t)},e}(),it=function(){function e(e,t){var n=this;this.element=e,this.delegate=t,this.started=!1,this.stringMap=new Map,this.mutationObserver=new MutationObserver((function(e){return n.processMutations(e)}))}return e.prototype.start=function(){this.started||(this.started=!0,this.mutationObserver.observe(this.element,{attributes:!0}),this.refresh())},e.prototype.stop=function(){this.started&&(this.mutationObserver.takeRecords(),this.mutationObserver.disconnect(),this.started=!1)},e.prototype.refresh=function(){if(this.started)for(var e=0,t=this.knownAttributeNames;e<t.length;e++){var n=t[e];this.refreshAttribute(n)}},e.prototype.processMutations=function(e){if(this.started)for(var t=0,n=e;t<n.length;t++){var r=n[t];this.processMutation(r)}},e.prototype.processMutation=function(e){var t=e.attributeName;t&&this.refreshAttribute(t)},e.prototype.refreshAttribute=function(e){var t=this.delegate.getStringMapKeyForAttribute(e);if(null!=t){this.stringMap.has(e)||this.stringMapKeyAdded(t,e);var n=this.element.getAttribute(e);this.stringMap.get(e)!=n&&this.stringMapValueChanged(n,t),null==n?(this.stringMap.delete(e),this.stringMapKeyRemoved(t,e)):this.stringMap.set(e,n)}},e.prototype.stringMapKeyAdded=function(e,t){this.delegate.stringMapKeyAdded&&this.delegate.stringMapKeyAdded(e,t)},e.prototype.stringMapValueChanged=function(e,t){this.delegate.stringMapValueChanged&&this.delegate.stringMapValueChanged(e,t)},e.prototype.stringMapKeyRemoved=function(e,t){this.delegate.stringMapKeyRemoved&&this.delegate.stringMapKeyRemoved(e,t)},Object.defineProperty(e.prototype,"knownAttributeNames",{get:function(){return Array.from(new Set(this.currentAttributeNames.concat(this.recordedAttributeNames)))},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"currentAttributeNames",{get:function(){return Array.from(this.element.attributes).map((function(e){return e.name}))},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"recordedAttributeNames",{get:function(){return Array.from(this.stringMap.keys())},enumerable:!1,configurable:!0}),e}();function ot(e,t,n){at(e,t).add(n)}function st(e,t,n){at(e,t).delete(n),function(e,t){var n=e.get(t);null!=n&&0==n.size&&e.delete(t)}(e,t)}function at(e,t){var n=e.get(t);return n||(n=new Set,e.set(t,n)),n}var ct,ut=function(){function e(){this.valuesByKey=new Map}return Object.defineProperty(e.prototype,"values",{get:function(){return Array.from(this.valuesByKey.values()).reduce((function(e,t){return e.concat(Array.from(t))}),[])},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"size",{get:function(){return Array.from(this.valuesByKey.values()).reduce((function(e,t){return e+t.size}),0)},enumerable:!1,configurable:!0}),e.prototype.add=function(e,t){ot(this.valuesByKey,e,t)},e.prototype.delete=function(e,t){st(this.valuesByKey,e,t)},e.prototype.has=function(e,t){var n=this.valuesByKey.get(e);return null!=n&&n.has(t)},e.prototype.hasKey=function(e){return this.valuesByKey.has(e)},e.prototype.hasValue=function(e){return Array.from(this.valuesByKey.values()).some((function(t){return t.has(e)}))},e.prototype.getValuesForKey=function(e){var t=this.valuesByKey.get(e);return t?Array.from(t):[]},e.prototype.getKeysForValue=function(e){return Array.from(this.valuesByKey).filter((function(t){return t[0],t[1].has(e)})).map((function(e){var t=e[0];return e[1],t}))},e}(),lt=window&&window.__extends||(ct=function(e,t){return(ct=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])})(e,t)},function(e,t){function n(){this.constructor=e}ct(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});!function(e){function t(){var t=e.call(this)||this;return t.keysByValue=new Map,t}lt(t,e),Object.defineProperty(t.prototype,"values",{get:function(){return Array.from(this.keysByValue.keys())},enumerable:!1,configurable:!0}),t.prototype.add=function(t,n){e.prototype.add.call(this,t,n),ot(this.keysByValue,n,t)},t.prototype.delete=function(t,n){e.prototype.delete.call(this,t,n),st(this.keysByValue,n,t)},t.prototype.hasValue=function(e){return this.keysByValue.has(e)},t.prototype.getKeysForValue=function(e){var t=this.keysByValue.get(e);return t?Array.from(t):[]}}(ut);var ft=function(){function e(e,t,n){this.attributeObserver=new rt(e,t,this),this.delegate=n,this.tokensByElement=new ut}return Object.defineProperty(e.prototype,"started",{get:function(){return this.attributeObserver.started},enumerable:!1,configurable:!0}),e.prototype.start=function(){this.attributeObserver.start()},e.prototype.stop=function(){this.attributeObserver.stop()},e.prototype.refresh=function(){this.attributeObserver.refresh()},Object.defineProperty(e.prototype,"element",{get:function(){return this.attributeObserver.element},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"attributeName",{get:function(){return this.attributeObserver.attributeName},enumerable:!1,configurable:!0}),e.prototype.elementMatchedAttribute=function(e){this.tokensMatched(this.readTokensForElement(e))},e.prototype.elementAttributeValueChanged=function(e){var t=this.refreshTokensForElement(e),n=t[0],r=t[1];this.tokensUnmatched(n),this.tokensMatched(r)},e.prototype.elementUnmatchedAttribute=function(e){this.tokensUnmatched(this.tokensByElement.getValuesForKey(e))},e.prototype.tokensMatched=function(e){var t=this;e.forEach((function(e){return t.tokenMatched(e)}))},e.prototype.tokensUnmatched=function(e){var t=this;e.forEach((function(e){return t.tokenUnmatched(e)}))},e.prototype.tokenMatched=function(e){this.delegate.tokenMatched(e),this.tokensByElement.add(e.element,e)},e.prototype.tokenUnmatched=function(e){this.delegate.tokenUnmatched(e),this.tokensByElement.delete(e.element,e)},e.prototype.refreshTokensForElement=function(e){var t=this.tokensByElement.getValuesForKey(e),n=this.readTokensForElement(e),r=function(e,t){var n=Math.max(e.length,t.length);return Array.from({length:n},(function(n,r){return[e[r],t[r]]}))}(t,n).findIndex((function(e){return!function(e,t){return e&&t&&e.index==t.index&&e.content==t.content}(e[0],e[1])}));return-1==r?[[],[]]:[t.slice(r),n.slice(r)]},e.prototype.readTokensForElement=function(e){var t=this.attributeName;return function(e,t,n){return e.trim().split(/\s+/).filter((function(e){return e.length})).map((function(e,r){return{element:t,attributeName:n,content:e,index:r}}))}(e.getAttribute(t)||"",e,t)},e}();var pt=function(){function e(e,t,n){this.tokenListObserver=new ft(e,t,this),this.delegate=n,this.parseResultsByToken=new WeakMap,this.valuesByTokenByElement=new WeakMap}return Object.defineProperty(e.prototype,"started",{get:function(){return this.tokenListObserver.started},enumerable:!1,configurable:!0}),e.prototype.start=function(){this.tokenListObserver.start()},e.prototype.stop=function(){this.tokenListObserver.stop()},e.prototype.refresh=function(){this.tokenListObserver.refresh()},Object.defineProperty(e.prototype,"element",{get:function(){return this.tokenListObserver.element},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"attributeName",{get:function(){return this.tokenListObserver.attributeName},enumerable:!1,configurable:!0}),e.prototype.tokenMatched=function(e){var t=e.element,n=this.fetchParseResultForToken(e).value;n&&(this.fetchValuesByTokenForElement(t).set(e,n),this.delegate.elementMatchedValue(t,n))},e.prototype.tokenUnmatched=function(e){var t=e.element,n=this.fetchParseResultForToken(e).value;n&&(this.fetchValuesByTokenForElement(t).delete(e),this.delegate.elementUnmatchedValue(t,n))},e.prototype.fetchParseResultForToken=function(e){var t=this.parseResultsByToken.get(e);return t||(t=this.parseToken(e),this.parseResultsByToken.set(e,t)),t},e.prototype.fetchValuesByTokenForElement=function(e){var t=this.valuesByTokenByElement.get(e);return t||(t=new Map,this.valuesByTokenByElement.set(e,t)),t},e.prototype.parseToken=function(e){try{return{value:this.delegate.parseValueForToken(e)}}catch(e){return{error:e}}},e}(),dt=function(){function e(e,t){this.context=e,this.delegate=t,this.bindingsByAction=new Map}return e.prototype.start=function(){this.valueListObserver||(this.valueListObserver=new pt(this.element,this.actionAttribute,this),this.valueListObserver.start())},e.prototype.stop=function(){this.valueListObserver&&(this.valueListObserver.stop(),delete this.valueListObserver,this.disconnectAllActions())},Object.defineProperty(e.prototype,"element",{get:function(){return this.context.element},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"identifier",{get:function(){return this.context.identifier},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"actionAttribute",{get:function(){return this.schema.actionAttribute},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"schema",{get:function(){return this.context.schema},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"bindings",{get:function(){return Array.from(this.bindingsByAction.values())},enumerable:!1,configurable:!0}),e.prototype.connectAction=function(e){var t=new tt(this.context,e);this.bindingsByAction.set(e,t),this.delegate.bindingConnected(t)},e.prototype.disconnectAction=function(e){var t=this.bindingsByAction.get(e);t&&(this.bindingsByAction.delete(e),this.delegate.bindingDisconnected(t))},e.prototype.disconnectAllActions=function(){var e=this;this.bindings.forEach((function(t){return e.delegate.bindingDisconnected(t)})),this.bindingsByAction.clear()},e.prototype.parseValueForToken=function(e){var t=Ge.forToken(e);if(t.identifier==this.identifier)return t},e.prototype.elementMatchedValue=function(e,t){this.connectAction(t)},e.prototype.elementUnmatchedValue=function(e,t){this.disconnectAction(t)},e}(),ht=function(){function e(e,t){this.context=e,this.receiver=t,this.stringMapObserver=new it(this.element,this),this.valueDescriptorMap=this.controller.valueDescriptorMap,this.invokeChangedCallbacksForDefaultValues()}return e.prototype.start=function(){this.stringMapObserver.start()},e.prototype.stop=function(){this.stringMapObserver.stop()},Object.defineProperty(e.prototype,"element",{get:function(){return this.context.element},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"controller",{get:function(){return this.context.controller},enumerable:!1,configurable:!0}),e.prototype.getStringMapKeyForAttribute=function(e){if(e in this.valueDescriptorMap)return this.valueDescriptorMap[e].name},e.prototype.stringMapValueChanged=function(e,t){this.invokeChangedCallbackForValue(t)},e.prototype.invokeChangedCallbacksForDefaultValues=function(){for(var e=0,t=this.valueDescriptors;e<t.length;e++){var n=t[e],r=n.key,i=n.name;null==n.defaultValue||this.controller.data.has(r)||this.invokeChangedCallbackForValue(i)}},e.prototype.invokeChangedCallbackForValue=function(e){var t=e+"Changed",n=this.receiver[t];if("function"==typeof n){var r=this.receiver[e];n.call(this.receiver,r)}},Object.defineProperty(e.prototype,"valueDescriptors",{get:function(){var e=this.valueDescriptorMap;return Object.keys(e).map((function(t){return e[t]}))},enumerable:!1,configurable:!0}),e}(),mt=function(){function e(e,t){this.module=e,this.scope=t,this.controller=new e.controllerConstructor(this),this.bindingObserver=new dt(this,this.dispatcher),this.valueObserver=new ht(this,this.controller);try{this.controller.initialize()}catch(e){this.handleError(e,"initializing controller")}}return e.prototype.connect=function(){this.bindingObserver.start(),this.valueObserver.start();try{this.controller.connect()}catch(e){this.handleError(e,"connecting controller")}},e.prototype.disconnect=function(){try{this.controller.disconnect()}catch(e){this.handleError(e,"disconnecting controller")}this.valueObserver.stop(),this.bindingObserver.stop()},Object.defineProperty(e.prototype,"application",{get:function(){return this.module.application},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"identifier",{get:function(){return this.module.identifier},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"schema",{get:function(){return this.application.schema},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"dispatcher",{get:function(){return this.application.dispatcher},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"element",{get:function(){return this.scope.element},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"parentElement",{get:function(){return this.element.parentElement},enumerable:!1,configurable:!0}),e.prototype.handleError=function(e,t,n){void 0===n&&(n={});var r=this,i=r.identifier,o=r.controller,s=r.element;n=Object.assign({identifier:i,controller:o,element:s},n),this.application.handleError(e,"Error "+t,n)},e}();function gt(e,t){var n=vt(e);return Array.from(n.reduce((function(e,n){return function(e,t){var n=e[t];return Array.isArray(n)?n:[]}(n,t).forEach((function(t){return e.add(t)})),e}),new Set))}function yt(e,t){return vt(e).reduce((function(e,n){return e.push.apply(e,function(e,t){var n=e[t];return n?Object.keys(n).map((function(e){return[e,n[e]]})):[]}(n,t)),e}),[])}function vt(e){for(var t=[];e;)t.push(e),e=Object.getPrototypeOf(e);return t.reverse()}var bt=window&&window.__extends||function(){var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])})(t,n)};return function(t,n){function r(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),wt=window&&window.__spreadArrays||function(){for(var e=0,t=0,n=arguments.length;t<n;t++)e+=arguments[t].length;var r=Array(e),i=0;for(t=0;t<n;t++)for(var o=arguments[t],s=0,a=o.length;s<a;s++,i++)r[i]=o[s];return r};function Ot(e){return function(e,t){var n=Tt(e),r=function(e,t){return Et(t).reduce((function(n,r){var i,o=function(e,t,n){var r=Object.getOwnPropertyDescriptor(e,n);if(!r||!("value"in r)){var i=Object.getOwnPropertyDescriptor(t,n).value;return r&&(i.get=r.get||i.get,i.set=r.set||i.set),i}}(e,t,r);return o&&Object.assign(n,((i={})[r]=o,i)),n}),{})}(e.prototype,t);return Object.defineProperties(n.prototype,r),n}(e,function(e){return gt(e,"blessings").reduce((function(t,n){var r=n(e);for(var i in r){var o=t[i]||{};t[i]=Object.assign(o,r[i])}return t}),{})}(e))}var Et="function"==typeof Object.getOwnPropertySymbols?function(e){return wt(Object.getOwnPropertyNames(e),Object.getOwnPropertySymbols(e))}:Object.getOwnPropertyNames,Tt=function(){function e(e){function t(){var n=this&&this instanceof t?this.constructor:void 0;return Reflect.construct(e,arguments,n)}return t.prototype=Object.create(e.prototype,{constructor:{value:t}}),Reflect.setPrototypeOf(t,e),t}try{return(t=e((function(){this.a.call(this)}))).prototype.a=function(){},new t,e}catch(e){return function(e){return function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return bt(t,e),t}(e)}}var t}();var At=function(){function e(e,t){this.application=e,this.definition=function(e){return{identifier:e.identifier,controllerConstructor:Ot(e.controllerConstructor)}}(t),this.contextsByScope=new WeakMap,this.connectedContexts=new Set}return Object.defineProperty(e.prototype,"identifier",{get:function(){return this.definition.identifier},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"controllerConstructor",{get:function(){return this.definition.controllerConstructor},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"contexts",{get:function(){return Array.from(this.connectedContexts)},enumerable:!1,configurable:!0}),e.prototype.connectContextForScope=function(e){var t=this.fetchContextForScope(e);this.connectedContexts.add(t),t.connect()},e.prototype.disconnectContextForScope=function(e){var t=this.contextsByScope.get(e);t&&(this.connectedContexts.delete(t),t.disconnect())},e.prototype.fetchContextForScope=function(e){var t=this.contextsByScope.get(e);return t||(t=new mt(this,e),this.contextsByScope.set(e,t)),t},e}(),kt=function(){function e(e){this.scope=e}return e.prototype.has=function(e){return this.data.has(this.getDataKey(e))},e.prototype.get=function(e){return this.data.get(this.getDataKey(e))},e.prototype.getAttributeName=function(e){return this.data.getAttributeNameForKey(this.getDataKey(e))},e.prototype.getDataKey=function(e){return e+"-class"},Object.defineProperty(e.prototype,"data",{get:function(){return this.scope.data},enumerable:!1,configurable:!0}),e}();function xt(e){return e.replace(/(?:[_-])([a-z0-9])/g,(function(e,t){return t.toUpperCase()}))}function Ct(e){return e.charAt(0).toUpperCase()+e.slice(1)}function Lt(e){return e.replace(/([A-Z])/g,(function(e,t){return"-"+t.toLowerCase()}))}var jt=function(){function e(e){this.scope=e}return Object.defineProperty(e.prototype,"element",{get:function(){return this.scope.element},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"identifier",{get:function(){return this.scope.identifier},enumerable:!1,configurable:!0}),e.prototype.get=function(e){var t=this.getAttributeNameForKey(e);return this.element.getAttribute(t)},e.prototype.set=function(e,t){var n=this.getAttributeNameForKey(e);return this.element.setAttribute(n,t),this.get(e)},e.prototype.has=function(e){var t=this.getAttributeNameForKey(e);return this.element.hasAttribute(t)},e.prototype.delete=function(e){if(this.has(e)){var t=this.getAttributeNameForKey(e);return this.element.removeAttribute(t),!0}return!1},e.prototype.getAttributeNameForKey=function(e){return"data-"+this.identifier+"-"+Lt(e)},e}(),Pt=function(){function e(e){this.warnedKeysByObject=new WeakMap,this.logger=e}return e.prototype.warn=function(e,t,n){var r=this.warnedKeysByObject.get(e);r||(r=new Set,this.warnedKeysByObject.set(e,r)),r.has(t)||(r.add(t),this.logger.warn(n,e))},e}();function Mt(e,t){return"["+e+'~="'+t+'"]'}var Bt=window&&window.__spreadArrays||function(){for(var e=0,t=0,n=arguments.length;t<n;t++)e+=arguments[t].length;var r=Array(e),i=0;for(t=0;t<n;t++)for(var o=arguments[t],s=0,a=o.length;s<a;s++,i++)r[i]=o[s];return r},St=function(){function e(e){this.scope=e}return Object.defineProperty(e.prototype,"element",{get:function(){return this.scope.element},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"identifier",{get:function(){return this.scope.identifier},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"schema",{get:function(){return this.scope.schema},enumerable:!1,configurable:!0}),e.prototype.has=function(e){return null!=this.find(e)},e.prototype.find=function(){for(var e=this,t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];return t.reduce((function(t,n){return t||e.findTarget(n)||e.findLegacyTarget(n)}),void 0)},e.prototype.findAll=function(){for(var e=this,t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];return t.reduce((function(t,n){return Bt(t,e.findAllTargets(n),e.findAllLegacyTargets(n))}),[])},e.prototype.findTarget=function(e){var t=this.getSelectorForTargetName(e);return this.scope.findElement(t)},e.prototype.findAllTargets=function(e){var t=this.getSelectorForTargetName(e);return this.scope.findAllElements(t)},e.prototype.getSelectorForTargetName=function(e){return Mt("data-"+this.identifier+"-target",e)},e.prototype.findLegacyTarget=function(e){var t=this.getLegacySelectorForTargetName(e);return this.deprecate(this.scope.findElement(t),e)},e.prototype.findAllLegacyTargets=function(e){var t=this,n=this.getLegacySelectorForTargetName(e);return this.scope.findAllElements(n).map((function(n){return t.deprecate(n,e)}))},e.prototype.getLegacySelectorForTargetName=function(e){var t=this.identifier+"."+e;return Mt(this.schema.targetAttribute,t)},e.prototype.deprecate=function(e,t){if(e){var n=this.identifier,r=this.schema.targetAttribute;this.guide.warn(e,"target:"+t,"Please replace "+r+'="'+n+"."+t+'" with data-'+n+'-target="'+t+'". The '+r+" attribute is deprecated and will be removed in a future version of Stimulus.")}return e},Object.defineProperty(e.prototype,"guide",{get:function(){return this.scope.guide},enumerable:!1,configurable:!0}),e}(),_t=window&&window.__spreadArrays||function(){for(var e=0,t=0,n=arguments.length;t<n;t++)e+=arguments[t].length;var r=Array(e),i=0;for(t=0;t<n;t++)for(var o=arguments[t],s=0,a=o.length;s<a;s++,i++)r[i]=o[s];return r},Dt=function(){function e(e,t,n,r){var i=this;this.targets=new St(this),this.classes=new kt(this),this.data=new jt(this),this.containsElement=function(e){return e.closest(i.controllerSelector)===i.element},this.schema=e,this.element=t,this.identifier=n,this.guide=new Pt(r)}return e.prototype.findElement=function(e){return this.element.matches(e)?this.element:this.queryElements(e).find(this.containsElement)},e.prototype.findAllElements=function(e){return _t(this.element.matches(e)?[this.element]:[],this.queryElements(e).filter(this.containsElement))},e.prototype.queryElements=function(e){return Array.from(this.element.querySelectorAll(e))},Object.defineProperty(e.prototype,"controllerSelector",{get:function(){return Mt(this.schema.controllerAttribute,this.identifier)},enumerable:!1,configurable:!0}),e}(),Nt=function(){function e(e,t,n){this.element=e,this.schema=t,this.delegate=n,this.valueListObserver=new pt(this.element,this.controllerAttribute,this),this.scopesByIdentifierByElement=new WeakMap,this.scopeReferenceCounts=new WeakMap}return e.prototype.start=function(){this.valueListObserver.start()},e.prototype.stop=function(){this.valueListObserver.stop()},Object.defineProperty(e.prototype,"controllerAttribute",{get:function(){return this.schema.controllerAttribute},enumerable:!1,configurable:!0}),e.prototype.parseValueForToken=function(e){var t=e.element,n=e.content,r=this.fetchScopesByIdentifierForElement(t),i=r.get(n);return i||(i=this.delegate.createScopeForElementAndIdentifier(t,n),r.set(n,i)),i},e.prototype.elementMatchedValue=function(e,t){var n=(this.scopeReferenceCounts.get(t)||0)+1;this.scopeReferenceCounts.set(t,n),1==n&&this.delegate.scopeConnected(t)},e.prototype.elementUnmatchedValue=function(e,t){var n=this.scopeReferenceCounts.get(t);n&&(this.scopeReferenceCounts.set(t,n-1),1==n&&this.delegate.scopeDisconnected(t))},e.prototype.fetchScopesByIdentifierForElement=function(e){var t=this.scopesByIdentifierByElement.get(e);return t||(t=new Map,this.scopesByIdentifierByElement.set(e,t)),t},e}(),Vt=function(){function e(e){this.application=e,this.scopeObserver=new Nt(this.element,this.schema,this),this.scopesByIdentifier=new ut,this.modulesByIdentifier=new Map}return Object.defineProperty(e.prototype,"element",{get:function(){return this.application.element},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"schema",{get:function(){return this.application.schema},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"logger",{get:function(){return this.application.logger},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"controllerAttribute",{get:function(){return this.schema.controllerAttribute},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"modules",{get:function(){return Array.from(this.modulesByIdentifier.values())},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"contexts",{get:function(){return this.modules.reduce((function(e,t){return e.concat(t.contexts)}),[])},enumerable:!1,configurable:!0}),e.prototype.start=function(){this.scopeObserver.start()},e.prototype.stop=function(){this.scopeObserver.stop()},e.prototype.loadDefinition=function(e){this.unloadIdentifier(e.identifier);var t=new At(this.application,e);this.connectModule(t)},e.prototype.unloadIdentifier=function(e){var t=this.modulesByIdentifier.get(e);t&&this.disconnectModule(t)},e.prototype.getContextForElementAndIdentifier=function(e,t){var n=this.modulesByIdentifier.get(t);if(n)return n.contexts.find((function(t){return t.element==e}))},e.prototype.handleError=function(e,t,n){this.application.handleError(e,t,n)},e.prototype.createScopeForElementAndIdentifier=function(e,t){return new Dt(this.schema,e,t,this.logger)},e.prototype.scopeConnected=function(e){this.scopesByIdentifier.add(e.identifier,e);var t=this.modulesByIdentifier.get(e.identifier);t&&t.connectContextForScope(e)},e.prototype.scopeDisconnected=function(e){this.scopesByIdentifier.delete(e.identifier,e);var t=this.modulesByIdentifier.get(e.identifier);t&&t.disconnectContextForScope(e)},e.prototype.connectModule=function(e){this.modulesByIdentifier.set(e.identifier,e),this.scopesByIdentifier.getValuesForKey(e.identifier).forEach((function(t){return e.connectContextForScope(t)}))},e.prototype.disconnectModule=function(e){this.modulesByIdentifier.delete(e.identifier),this.scopesByIdentifier.getValuesForKey(e.identifier).forEach((function(t){return e.disconnectContextForScope(t)}))},e}(),It={controllerAttribute:"data-controller",actionAttribute:"data-action",targetAttribute:"data-target"},Ft=window&&window.__awaiter||function(e,t,n,r){return new(n||(n=Promise))((function(i,o){function s(e){try{c(r.next(e))}catch(e){o(e)}}function a(e){try{c(r.throw(e))}catch(e){o(e)}}function c(e){var t;e.done?i(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(s,a)}c((r=r.apply(e,t||[])).next())}))},Rt=window&&window.__generator||function(e,t){var n,r,i,o,s={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(o){return function(a){return function(o){if(n)throw new TypeError("Generator is already executing.");for(;s;)try{if(n=1,r&&(i=2&o[0]?r.return:o[0]?r.throw||((i=r.return)&&i.call(r),0):r.next)&&!(i=i.call(r,o[1])).done)return i;switch(r=0,i&&(o=[2&o[0],i.value]),o[0]){case 0:case 1:i=o;break;case 4:return s.label++,{value:o[1],done:!1};case 5:s.label++,r=o[1],o=[0];continue;case 7:o=s.ops.pop(),s.trys.pop();continue;default:if(!(i=s.trys,(i=i.length>0&&i[i.length-1])||6!==o[0]&&2!==o[0])){s=0;continue}if(3===o[0]&&(!i||o[1]>i[0]&&o[1]<i[3])){s.label=o[1];break}if(6===o[0]&&s.label<i[1]){s.label=i[1],i=o;break}if(i&&s.label<i[2]){s.label=i[2],s.ops.push(o);break}i[2]&&s.ops.pop(),s.trys.pop();continue}o=t.call(e,s)}catch(e){o=[6,e],r=0}finally{n=i=0}if(5&o[0])throw o[1];return{value:o[0]?o[1]:void 0,done:!0}}([o,a])}}},Kt=window&&window.__spreadArrays||function(){for(var e=0,t=0,n=arguments.length;t<n;t++)e+=arguments[t].length;var r=Array(e),i=0;for(t=0;t<n;t++)for(var o=arguments[t],s=0,a=o.length;s<a;s++,i++)r[i]=o[s];return r},Wt=function(){function e(e,t){void 0===e&&(e=document.documentElement),void 0===t&&(t=It),this.logger=console,this.element=e,this.schema=t,this.dispatcher=new Je(this),this.router=new Vt(this)}return e.start=function(t,n){var r=new e(t,n);return r.start(),r},e.prototype.start=function(){return Ft(this,void 0,void 0,(function(){return Rt(this,(function(e){switch(e.label){case 0:return[4,new Promise((function(e){"loading"==document.readyState?document.addEventListener("DOMContentLoaded",e):e()}))];case 1:return e.sent(),this.dispatcher.start(),this.router.start(),[2]}}))}))},e.prototype.stop=function(){this.dispatcher.stop(),this.router.stop()},e.prototype.register=function(e,t){this.load({identifier:e,controllerConstructor:t})},e.prototype.load=function(e){for(var t=this,n=[],r=1;r<arguments.length;r++)n[r-1]=arguments[r];var i=Array.isArray(e)?e:Kt([e],n);i.forEach((function(e){return t.router.loadDefinition(e)}))},e.prototype.unload=function(e){for(var t=this,n=[],r=1;r<arguments.length;r++)n[r-1]=arguments[r];var i=Array.isArray(e)?e:Kt([e],n);i.forEach((function(e){return t.router.unloadIdentifier(e)}))},Object.defineProperty(e.prototype,"controllers",{get:function(){return this.router.contexts.map((function(e){return e.controller}))},enumerable:!1,configurable:!0}),e.prototype.getControllerForElementAndIdentifier=function(e,t){var n=this.router.getContextForElementAndIdentifier(e,t);return n?n.controller:null},e.prototype.handleError=function(e,t,n){this.logger.error("%s\n\n%o\n\n%o",t,e,n)},e}();function Ut(e){return gt(e,"classes").reduce((function(e,t){return Object.assign(e,((r={})[i=(n=t)+"Class"]={get:function(){var e=this.classes;if(e.has(n))return e.get(n);var t=e.getAttributeName(n);throw new Error('Missing attribute "'+t+'"')}},r["has"+Ct(i)]={get:function(){return this.classes.has(n)}},r));var n,r,i}),{})}function Ht(e){return gt(e,"targets").reduce((function(e,t){return Object.assign(e,((r={})[(n=t)+"Target"]={get:function(){var e=this.targets.find(n);if(e)return e;throw new Error('Missing target element "'+this.identifier+"."+n+'"')}},r[n+"Targets"]={get:function(){return this.targets.findAll(n)}},r["has"+Ct(n)+"Target"]={get:function(){return this.targets.has(n)}},r));var n,r}),{})}function qt(e){var t=yt(e,"values"),n={valueDescriptorMap:{get:function(){var e=this;return t.reduce((function(t,n){var r,i=zt(n),o=e.data.getAttributeNameForKey(i.key);return Object.assign(t,((r={})[o]=i,r))}),{})}}};return t.reduce((function(e,t){return Object.assign(e,function(e){var t,n=zt(e),r=n.type,i=n.key,o=n.name,s=Yt[r],a=Jt[r]||Jt.default;return(t={})[o]={get:function(){var e=this.data.get(i);return null!==e?s(e):n.defaultValue},set:function(e){void 0===e?this.data.delete(i):this.data.set(i,a(e))}},t["has"+Ct(o)]={get:function(){return this.data.has(i)}},t}(t))}),n)}function zt(e){return function(e,t){var n=Lt(e)+"-value";return{type:t,key:n,name:xt(n),get defaultValue(){return $t[t]}}}(e[0],function(e){switch(e){case Array:return"array";case Boolean:return"boolean";case Number:return"number";case Object:return"object";case String:return"string"}throw new Error('Unknown value type constant "'+e+'"')}(e[1]))}var $t={get array(){return[]},boolean:!1,number:0,get object(){return{}},string:""},Yt={array:function(e){var t=JSON.parse(e);if(!Array.isArray(t))throw new TypeError("Expected array");return t},boolean:function(e){return!("0"==e||"false"==e)},number:function(e){return parseFloat(e)},object:function(e){var t=JSON.parse(e);if(null===t||"object"!=typeof t||Array.isArray(t))throw new TypeError("Expected object");return t},string:function(e){return e}},Jt={default:function(e){return""+e},array:Xt,object:Xt};function Xt(e){return JSON.stringify(e)}var Qt=function(){function e(e){this.context=e}return Object.defineProperty(e.prototype,"application",{get:function(){return this.context.application},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"scope",{get:function(){return this.context.scope},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"element",{get:function(){return this.scope.element},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"identifier",{get:function(){return this.scope.identifier},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"targets",{get:function(){return this.scope.targets},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"classes",{get:function(){return this.scope.classes},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"data",{get:function(){return this.scope.data},enumerable:!1,configurable:!0}),e.prototype.initialize=function(){},e.prototype.connect=function(){},e.prototype.disconnect=function(){},e.blessings=[Ut,Ht,qt],e.targets=[],e.values={},e}();function Gt(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Zt(e,t,n){return t&&Gt(e.prototype,t),n&&Gt(e,n),e}function en(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,e.__proto__=t}(function(e){function t(){return e.apply(this,arguments)||this}en(t,e);var n=t.prototype;return n.initialize=function(){this.hide()},n.connect=function(){var e=this;setTimeout((function(){e.show()}),200),this.hasDismissAfterValue&&setTimeout((function(){e.close()}),this.dismissAfterValue)},n.close=function(){var e=this;this.hide(),setTimeout((function(){e.element.remove()}),1100)},n.show=function(){this.element.setAttribute("style","transition: 1s; transform:translate(0, 0);")},n.hide=function(){this.element.setAttribute("style","transition: 1s; transform:translate(400px, 0);")},t}(Qt)).values={dismissAfter:Number},(function(e){function t(){return e.apply(this,arguments)||this}en(t,e);var n=t.prototype;return n.connect=function(){this.timeout=null,this.duration=this.data.get("duration")||1e3},n.save=function(){var e=this;clearTimeout(this.timeout),this.timeout=setTimeout((function(){e.statusTarget.textContent="Saving...",Rails.fire(e.formTarget,"submit")}),this.duration)},n.success=function(){this.setStatus("Saved!")},n.error=function(){this.setStatus("Unable to save!")},n.setStatus=function(e){var t=this;this.statusTarget.textContent=e,this.timeout=setTimeout((function(){t.statusTarget.textContent=""}),2e3)},t}(Qt)).targets=["form","status"];var tn=function(e){function t(){for(var t,n=arguments.length,r=new Array(n),i=0;i<n;i++)r[i]=arguments[i];return(t=e.call.apply(e,[this].concat(r))||this)._onMenuButtonKeydown=function(e){switch(e.keyCode){case 13:case 32:e.preventDefault(),t.toggle()}},t}en(t,e);var n=t.prototype;return n.connect=function(){this.toggleClass=this.data.get("class")||"hidden",this.visibleClass=this.data.get("visibleClass")||null,this.invisibleClass=this.data.get("invisibleClass")||null,this.activeClass=this.data.get("activeClass")||null,this.enteringClass=this.data.get("enteringClass")||null,this.leavingClass=this.data.get("leavingClass")||null,this.hasButtonTarget&&this.buttonTarget.addEventListener("keydown",this._onMenuButtonKeydown),this.element.setAttribute("aria-haspopup","true")},n.disconnect=function(){this.hasButtonTarget&&this.buttonTarget.removeEventListener("keydown",this._onMenuButtonKeydown)},n.toggle=function(){this.openValue=!this.openValue},n.openValueChanged=function(){this.openValue?this._show():this._hide()},n._show=function(e){var t=this;setTimeout(function(){t.menuTarget.classList.remove(t.toggleClass),t.element.setAttribute("aria-expanded","true"),t._enteringClassList[0].forEach(function(e){t.menuTarget.classList.add(e)}.bind(t)),t._activeClassList[0].forEach((function(e){t.activeTarget.classList.add(e)})),t._invisibleClassList[0].forEach((function(e){return t.menuTarget.classList.remove(e)})),t._visibleClassList[0].forEach((function(e){t.menuTarget.classList.add(e)})),setTimeout(function(){t._enteringClassList[0].forEach((function(e){return t.menuTarget.classList.remove(e)}))}.bind(t),t.enterTimeout[0]),"function"==typeof e&&e()}.bind(this))},n._hide=function(e){var t=this;setTimeout(function(){t.element.setAttribute("aria-expanded","false"),t._invisibleClassList[0].forEach((function(e){return t.menuTarget.classList.add(e)})),t._visibleClassList[0].forEach((function(e){return t.menuTarget.classList.remove(e)})),t._activeClassList[0].forEach((function(e){return t.activeTarget.classList.remove(e)})),t._leavingClassList[0].forEach((function(e){return t.menuTarget.classList.add(e)})),setTimeout(function(){t._leavingClassList[0].forEach((function(e){return t.menuTarget.classList.remove(e)})),"function"==typeof e&&e(),t.menuTarget.classList.add(t.toggleClass)}.bind(t),t.leaveTimeout[0])}.bind(this))},n.show=function(){this.openValue=!0},n.hide=function(e){!1===this.element.contains(e.target)&&this.openValue&&(this.openValue=!1)},Zt(t,[{key:"activeTarget",get:function(){return this.data.has("activeTarget")?document.querySelector(this.data.get("activeTarget")):this.element}},{key:"_activeClassList",get:function(){return this.activeClass?this.activeClass.split(",").map((function(e){return e.split(" ")})):[[],[]]}},{key:"_visibleClassList",get:function(){return this.visibleClass?this.visibleClass.split(",").map((function(e){return e.split(" ")})):[[],[]]}},{key:"_invisibleClassList",get:function(){return this.invisibleClass?this.invisibleClass.split(",").map((function(e){return e.split(" ")})):[[],[]]}},{key:"_enteringClassList",get:function(){return this.enteringClass?this.enteringClass.split(",").map((function(e){return e.split(" ")})):[[],[]]}},{key:"_leavingClassList",get:function(){return this.leavingClass?this.leavingClass.split(",").map((function(e){return e.split(" ")})):[[],[]]}},{key:"enterTimeout",get:function(){return(this.data.get("enterTimeout")||"0,0").split(",").map((function(e){return parseInt(e)}))}},{key:"leaveTimeout",get:function(){return(this.data.get("leaveTimeout")||"0,0").split(",").map((function(e){return parseInt(e)}))}}]),t}(Qt);tn.targets=["menu","button"],tn.values={open:Boolean},(function(e){function t(){return e.apply(this,arguments)||this}en(t,e);var n=t.prototype;return n.connect=function(){this.toggleClass=this.data.get("class")||"hidden",this.backgroundId=this.data.get("backgroundId")||"modal-background",this.backgroundHtml=this.data.get("backgroundHtml")||this._backgroundHTML(),this.allowBackgroundClose="true"===(this.data.get("allowBackgroundClose")||"true"),this.preventDefaultActionOpening="true"===(this.data.get("preventDefaultActionOpening")||"true"),this.preventDefaultActionClosing="true"===(this.data.get("preventDefaultActionClosing")||"true")},n.disconnect=function(){this.close()},n.open=function(e){this.preventDefaultActionOpening&&e.preventDefault(),e.target.blur&&e.target.blur(),this.lockScroll(),this.containerTarget.classList.remove(this.toggleClass),this.data.get("disable-backdrop")||(document.body.insertAdjacentHTML("beforeend",this.backgroundHtml),this.background=document.querySelector("#"+this.backgroundId))},n.close=function(e){e&&this.preventDefaultActionClosing&&e.preventDefault(),this.unlockScroll(),this.containerTarget.classList.add(this.toggleClass),this.background&&this.background.remove()},n.closeBackground=function(e){this.allowBackgroundClose&&e.target===this.containerTarget&&this.close(e)},n.closeWithKeyboard=function(e){27!==e.keyCode||this.containerTarget.classList.contains(this.toggleClass)||this.close(e)},n._backgroundHTML=function(){return'<div id="'+this.backgroundId+'" class="fixed top-0 left-0 w-full h-full" style="background-color: rgba(0, 0, 0, 0.8); z-index: 9998;"></div>'},n.lockScroll=function(){var e=window.innerWidth-document.documentElement.clientWidth;document.body.style.paddingRight=e+"px",this.saveScrollPosition(),document.body.classList.add("fixed","inset-x-0","overflow-hidden"),document.body.style.top="-"+this.scrollPosition+"px"},n.unlockScroll=function(){document.body.style.paddingRight=null,document.body.classList.remove("fixed","inset-x-0","overflow-hidden"),this.restoreScrollPosition(),document.body.style.top=null},n.saveScrollPosition=function(){this.scrollPosition=window.pageYOffset||document.body.scrollTop},n.restoreScrollPosition=function(){document.documentElement.scrollTop=this.scrollPosition},t}(Qt)).targets=["container"],(function(e){function t(){return e.apply(this,arguments)||this}en(t,e);var n=t.prototype;return n.connect=function(){var e=this;this.activeTabClasses=(this.data.get("activeTab")||"active").split(" "),this.inactiveTabClasses=(this.data.get("inactiveTab")||"inactive").split(" "),this.anchor&&(this.index=this.tabTargets.findIndex((function(t){return t.id===e.anchor}))),this.showTab()},n.change=function(e){e.preventDefault(),this.index=e.currentTarget.dataset.index?e.currentTarget.dataset.index:e.currentTarget.dataset.id?this.tabTargets.findIndex((function(t){return t.id==e.currentTarget.dataset.id})):this.tabTargets.indexOf(e.currentTarget),window.dispatchEvent(new CustomEvent("tsc:tab-change"))},n.showTab=function(){var e=this;this.tabTargets.forEach((function(t,n){var r,i,o,s,a=e.panelTargets[n];n===e.index?(a.classList.remove("hidden"),(r=t.classList).remove.apply(r,e.inactiveTabClasses),(i=t.classList).add.apply(i,e.activeTabClasses),t.id&&(location.hash=t.id)):(a.classList.add("hidden"),(o=t.classList).remove.apply(o,e.activeTabClasses),(s=t.classList).add.apply(s,e.inactiveTabClasses))}))},Zt(t,[{key:"index",get:function(){return parseInt(this.data.get("index")||0)},set:function(e){this.data.set("index",e>=0?e:0),this.showTab()}},{key:"anchor",get:function(){return document.URL.split("#").length>1?document.URL.split("#")[1]:null}}]),t}(Qt)).targets=["tab","panel"];var nn=function(e){function t(){return e.apply(this,arguments)||this}en(t,e);var n=t.prototype;return n.connect=function(){this.toggleClass=this.data.get("class")||"hidden"},n.toggle=function(e){e.preventDefault(),this.openValue=!this.openValue},n.hide=function(e){e.preventDefault(),this.openValue=!1},n.show=function(e){e.preventDefault(),this.openValue=!0},n.openValueChanged=function(){var e=this;this.toggleClass&&this.toggleableTargets.forEach((function(t){t.classList.toggle(e.toggleClass)}))},t}(Qt);function rn(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function on(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function sn(e,t,n){return t&&on(e.prototype,t),n&&on(e,n),e}function an(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function cn(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&ln(e,t)}function un(e){return(un=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function ln(e,t){return(ln=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function fn(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}function pn(e,t,n){return(pn=fn()?Reflect.construct:function(e,t,n){var r=[null];r.push.apply(r,t);var i=new(Function.bind.apply(e,r));return n&&ln(i,n.prototype),i}).apply(null,arguments)}function dn(e,t){return!t||"object"!=typeof t&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function hn(e){var t=fn();return function(){var n,r=un(e);if(t){var i=un(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return dn(this,n)}}function mn(e){return function(e){if(Array.isArray(e))return gn(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(!e)return;if("string"==typeof e)return gn(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return gn(e,t)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function gn(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}nn.targets=["toggleable"],nn.values={open:Boolean},(function(e){function t(){return e.apply(this,arguments)||this}en(t,e);var n=t.prototype;return n.initialize=function(){this.contentTarget.setAttribute("style","transform:translate("+this.data.get("translateX")+", "+this.data.get("translateY")+");")},n.mouseOver=function(){this.contentTarget.classList.remove("hidden")},n.mouseOut=function(){this.contentTarget.classList.add("hidden")},t}(Qt)).targets=["content"],(function(e){function t(){return e.apply(this,arguments)||this}en(t,e);var n=t.prototype;return n._show=function(){var t=this;this.overlayTarget.classList.remove(this.toggleClass),e.prototype._show.call(this,function(){t._activeClassList[1].forEach((function(e){return t.overlayTarget.classList.add(e)})),t._invisibleClassList[1].forEach((function(e){return t.overlayTarget.classList.remove(e)})),t._visibleClassList[1].forEach((function(e){return t.overlayTarget.classList.add(e)})),setTimeout(function(){t._enteringClassList[1].forEach((function(e){return t.overlayTarget.classList.remove(e)}))}.bind(t),t.enterTimeout[1])}.bind(this))},n._hide=function(){var t=this;this._leavingClassList[1].forEach((function(e){return t.overlayTarget.classList.add(e)})),e.prototype._hide.call(this,function(){setTimeout(function(){t._visibleClassList[1].forEach((function(e){return t.overlayTarget.classList.remove(e)})),t._invisibleClassList[1].forEach((function(e){return t.overlayTarget.classList.add(e)})),t._activeClassList[1].forEach((function(e){return t.overlayTarget.classList.remove(e)})),t._leavingClassList[1].forEach((function(e){return t.overlayTarget.classList.remove(e)})),t.overlayTarget.classList.add(t.toggleClass)}.bind(t),t.leaveTimeout[1])}.bind(this))},t}(tn)).targets=["menu","overlay"],(function(e){function t(){return e.apply(this,arguments)||this}en(t,e);var n=t.prototype;return n.connect=function(){this.styleProperty=this.data.get("style")||"backgroundColor"},n.update=function(){this.preview=this.color},n._getContrastYIQ=function(e){return e=e.replace("#",""),(299*parseInt(e.substr(0,2),16)+587*parseInt(e.substr(2,2),16)+114*parseInt(e.substr(4,2),16))/1e3>=128?"#000":"#fff"},Zt(t,[{key:"preview",set:function(e){this.previewTarget.style[this.styleProperty]=e;var t=this._getContrastYIQ(e);"color"===this.styleProperty?this.previewTarget.style.backgroundColor=t:this.previewTarget.style.color=t}},{key:"color",get:function(){return this.colorTarget.value}}]),t}(Qt)).targets=["preview","color"];var yn=function(e){cn(n,e);var t=hn(n);function n(){return rn(this,n),t.apply(this,arguments)}return sn(n,[{key:"connect",value:function(){this.setCount()}},{key:"checkAll",value:function(){this.setAllCheckboxes(!0),this.setCount()}},{key:"checkNone",value:function(){this.setAllCheckboxes(!1),this.setCount()}},{key:"onChecked",value:function(){this.setCount()}},{key:"setAllCheckboxes",value:function(e){this.checkboxes.forEach((function(t){var n=t;n.disabled||(n.checked=e)}))}},{key:"setCount",value:function(){if(this.hasCountTarget){var e=this.selectedCheckboxes.length;this.countTarget.innerHTML="".concat(e," selected")}}},{key:"selectedCheckboxes",get:function(){return this.checkboxes.filter((function(e){return e.checked}))}},{key:"checkboxes",get:function(){return pn(Array,mn(this.element.querySelectorAll("input[type=checkbox]")))}}]),n}(Qt);an(yn,"targets",["count"]);var vn=function(e){cn(n,e);var t=hn(n);function n(){return rn(this,n),t.apply(this,arguments)}return sn(n,[{key:"selectAll",value:function(e){var t=e.target.checked;this.allTarget.indeterminate=!1,this._setAllCheckboxes(t),this._dispatch("change",{count:this.selectedCount})}},{key:"onSelected",value:function(){this.allTarget.indeterminate=!!this._indeterminate,this._dispatch("change",{count:this.selectedCount})}},{key:"selectedCount",get:function(){return this.selected.length}},{key:"selected",get:function(){return this.selectables.filter((function(e){return e.checked}))}},{key:"selectables",get:function(){return pn(Array,mn(this.selectableTargets))}},{key:"_setAllCheckboxes",value:function(e){this.selectables.forEach((function(t){var n=t;n.disabled||(n.checked=e)}))}},{key:"_indeterminate",get:function(){return this.selected.length!==this.selectableTargets.length&&this.selected.length>0}},{key:"_dispatch",value:function(e,t){window.dispatchEvent(new CustomEvent("rmp:select:".concat(e),{bubbles:!0,detail:t}))}}]),n}(Qt);an(vn,"targets",["all","selectable"]);var bn=function(e){cn(n,e);var t=hn(n);function n(){return rn(this,n),t.apply(this,arguments)}return sn(n,[{key:"apply",value:function(){location.href="".concat(window.location.pathname,"?").concat(this.params)}},{key:"post",value:function(){var e=document.head.querySelector('meta[name="csrf-token"]').content,t="".concat(window.location.pathname,"/destroy_all?").concat(this.params);fetch(t,{method:"DELETE",redirect:"follow",headers:{"Content-Type":"application/json",credentials:"same-origin"},body:JSON.stringify({authenticity_token:e})}).then((function(e){e.redirected&&(window.location.href=e.url)}))}},{key:"params",get:function(){return this.activeFilterTargets().map((function(e){return"".concat(e.name,"=").concat(e.value)})).join("&")}},{key:"activeFilterTargets",value:function(){return this.filterTargets.filter((function(e){return"checkbox"===e.type||"radio"===e.type?e.checked:e.value.length>0}))}}]),n}(Qt);an(bn,"targets",["filter"]);var wn=function(e){cn(n,e);var t=hn(n);function n(){return rn(this,n),t.apply(this,arguments)}return sn(n,[{key:"clear",value:function(){this.eventTarget.value=null,window.dispatchEvent(new CustomEvent("search-controller:submit",{}))}},{key:"submit",value:function(e){e.preventDefault(),"Enter"!==e.key&&"click"!==e.type||window.dispatchEvent(new CustomEvent("search-controller:submit",{}))}}]),n}(Qt);an(wn,"targets",["field"]);var On=function(e){cn(n,e);var t=hn(n);function n(){return rn(this,n),t.apply(this,arguments)}return sn(n,[{key:"enable",value:function(){this.enableTarget.disabled=!1}},{key:"disable",value:function(){this.enableTarget.disabled=!0}},{key:"change",value:function(e){e.type.match(/rmp:select:.*/)&&(e.detail.count>0?this.enable():this.disable())}}]),n}(Qt);an(On,"targets",["enable"]);var En=Wt.start();En.register("dropdown",tn),En.register("checklist",yn),En.register("selectable",vn),En.register("filters",bn),En.register("search",wn),En.register("enable",On),document.addEventListener("DOMContentLoaded",(function(){var e;!function(){var e=document.getElementById("profiled-requests-table");if(e)for(var t=e.rows,n=function(t){var n=e.rows[t],r=n.dataset.link;r&&(n.onclick=function(){window.location.href=r})},r=1;r<t.length;r++)n(r)}(),document.querySelectorAll(".trace-bar").forEach((function(e){$e(e,{trigger:"click",content:e.children[0],theme:"rmp",maxWidth:"700px",placement:"bottom",interactive:!0,onShow:function(e){e.popper.querySelector(".popover-close").addEventListener("click",(function(){e.hide()}))},onHide:function(e){e.popper.querySelector(".popover-close").removeEventListener("click",(function(){e.hide()}))}})})),(e=document.getElementById("trace-search"))&&e.addEventListener("keyup",(function(e){"Enter"===e.key&&(e.preventDefault(),document.getElementById("trace-form").submit())}))}),!1)}));
1
+ !function(e){"function"==typeof define&&define.amd?define(e):e()}((function(){"use strict";var e="top",t="bottom",n="right",r="left",i="auto",s=[e,t,n,r],o="start",a="end",c="viewport",l="popper",u=s.reduce((function(e,t){return e.concat([t+"-"+o,t+"-"+a])}),[]),h=[].concat(s,[i]).reduce((function(e,t){return e.concat([t,t+"-"+o,t+"-"+a])}),[]),d=["beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite"];function p(e){return e?(e.nodeName||"").toLowerCase():null}function f(e){if(null==e)return window;if("[object Window]"!==e.toString()){var t=e.ownerDocument;return t&&t.defaultView||window}return e}function g(e){return e instanceof f(e).Element||e instanceof Element}function m(e){return e instanceof f(e).HTMLElement||e instanceof HTMLElement}function v(e){return"undefined"!=typeof ShadowRoot&&(e instanceof f(e).ShadowRoot||e instanceof ShadowRoot)}var b={name:"applyStyles",enabled:!0,phase:"write",fn:function(e){var t=e.state;Object.keys(t.elements).forEach((function(e){var n=t.styles[e]||{},r=t.attributes[e]||{},i=t.elements[e];m(i)&&p(i)&&(Object.assign(i.style,n),Object.keys(r).forEach((function(e){var t=r[e];!1===t?i.removeAttribute(e):i.setAttribute(e,!0===t?"":t)})))}))},effect:function(e){var t=e.state,n={popper:{position:t.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(t.elements.popper.style,n.popper),t.styles=n,t.elements.arrow&&Object.assign(t.elements.arrow.style,n.arrow),function(){Object.keys(t.elements).forEach((function(e){var r=t.elements[e],i=t.attributes[e]||{},s=Object.keys(t.styles.hasOwnProperty(e)?t.styles[e]:n[e]).reduce((function(e,t){return e[t]="",e}),{});m(r)&&p(r)&&(Object.assign(r.style,s),Object.keys(i).forEach((function(e){r.removeAttribute(e)})))}))}},requires:["computeStyles"]};function y(e){return e.split("-")[0]}var w=Math.round;function T(e,t){void 0===t&&(t=!1);var n=e.getBoundingClientRect(),r=1,i=1;return m(e)&&t&&(r=n.width/e.offsetWidth||1,i=n.height/e.offsetHeight||1),{width:w(n.width/r),height:w(n.height/i),top:w(n.top/i),right:w(n.right/r),bottom:w(n.bottom/i),left:w(n.left/r),x:w(n.left/r),y:w(n.top/i)}}function E(e){var t=T(e),n=e.offsetWidth,r=e.offsetHeight;return Math.abs(t.width-n)<=1&&(n=t.width),Math.abs(t.height-r)<=1&&(r=t.height),{x:e.offsetLeft,y:e.offsetTop,width:n,height:r}}function O(e,t){var n=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(n&&v(n)){var r=t;do{if(r&&e.isSameNode(r))return!0;r=r.parentNode||r.host}while(r)}return!1}function A(e){return f(e).getComputedStyle(e)}function x(e){return["table","td","th"].indexOf(p(e))>=0}function k(e){return((g(e)?e.ownerDocument:e.document)||window.document).documentElement}function C(e){return"html"===p(e)?e:e.assignedSlot||e.parentNode||(v(e)?e.host:null)||k(e)}function L(e){return m(e)&&"fixed"!==A(e).position?e.offsetParent:null}function M(e){for(var t=f(e),n=L(e);n&&x(n)&&"static"===A(n).position;)n=L(n);return n&&("html"===p(n)||"body"===p(n)&&"static"===A(n).position)?t:n||function(e){var t=-1!==navigator.userAgent.toLowerCase().indexOf("firefox");if(-1!==navigator.userAgent.indexOf("Trident")&&m(e)&&"fixed"===A(e).position)return null;for(var n=C(e);m(n)&&["html","body"].indexOf(p(n))<0;){var r=A(n);if("none"!==r.transform||"none"!==r.perspective||"paint"===r.contain||-1!==["transform","perspective"].indexOf(r.willChange)||t&&"filter"===r.willChange||t&&r.filter&&"none"!==r.filter)return n;n=n.parentNode}return null}(e)||t}function D(e){return["top","bottom"].indexOf(e)>=0?"x":"y"}var B=Math.max,N=Math.min,S=Math.round;function j(e,t,n){return B(e,N(t,n))}function I(e){return Object.assign({},{top:0,right:0,bottom:0,left:0},e)}function V(e,t){return t.reduce((function(t,n){return t[n]=e,t}),{})}var F={top:"auto",right:"auto",bottom:"auto",left:"auto"};function $(i){var s,o=i.popper,a=i.popperRect,c=i.placement,l=i.offsets,u=i.position,h=i.gpuAcceleration,d=i.adaptive,p=i.roundOffsets,g=!0===p?function(e){var t=e.x,n=e.y,r=window.devicePixelRatio||1;return{x:S(S(t*r)/r)||0,y:S(S(n*r)/r)||0}}(l):"function"==typeof p?p(l):l,m=g.x,v=void 0===m?0:m,b=g.y,y=void 0===b?0:b,w=l.hasOwnProperty("x"),T=l.hasOwnProperty("y"),E=r,O=e,x=window;if(d){var C=M(o),L="clientHeight",D="clientWidth";C===f(o)&&"static"!==A(C=k(o)).position&&(L="scrollHeight",D="scrollWidth"),C=C,c===e&&(O=t,y-=C[L]-a.height,y*=h?1:-1),c===r&&(E=n,v-=C[D]-a.width,v*=h?1:-1)}var B,N=Object.assign({position:u},d&&F);return h?Object.assign({},N,((B={})[O]=T?"0":"",B[E]=w?"0":"",B.transform=(x.devicePixelRatio||1)<2?"translate("+v+"px, "+y+"px)":"translate3d("+v+"px, "+y+"px, 0)",B)):Object.assign({},N,((s={})[O]=T?y+"px":"",s[E]=w?v+"px":"",s.transform="",s))}var _={passive:!0};var P={left:"right",right:"left",bottom:"top",top:"bottom"};function R(e){return e.replace(/left|right|bottom|top/g,(function(e){return P[e]}))}var K={start:"end",end:"start"};function U(e){return e.replace(/start|end/g,(function(e){return K[e]}))}function W(e){var t=f(e);return{scrollLeft:t.pageXOffset,scrollTop:t.pageYOffset}}function H(e){return T(k(e)).left+W(e).scrollLeft}function q(e){var t=A(e),n=t.overflow,r=t.overflowX,i=t.overflowY;return/auto|scroll|overlay|hidden/.test(n+i+r)}function z(e){return["html","body","#document"].indexOf(p(e))>=0?e.ownerDocument.body:m(e)&&q(e)?e:z(C(e))}function Y(e,t){var n;void 0===t&&(t=[]);var r=z(e),i=r===(null==(n=e.ownerDocument)?void 0:n.body),s=f(r),o=i?[s].concat(s.visualViewport||[],q(r)?r:[]):r,a=t.concat(o);return i?a:a.concat(Y(C(o)))}function J(e){return Object.assign({},e,{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}function X(e,t){return t===c?J(function(e){var t=f(e),n=k(e),r=t.visualViewport,i=n.clientWidth,s=n.clientHeight,o=0,a=0;return r&&(i=r.width,s=r.height,/^((?!chrome|android).)*safari/i.test(navigator.userAgent)||(o=r.offsetLeft,a=r.offsetTop)),{width:i,height:s,x:o+H(e),y:a}}(e)):m(t)?function(e){var t=T(e);return t.top=t.top+e.clientTop,t.left=t.left+e.clientLeft,t.bottom=t.top+e.clientHeight,t.right=t.left+e.clientWidth,t.width=e.clientWidth,t.height=e.clientHeight,t.x=t.left,t.y=t.top,t}(t):J(function(e){var t,n=k(e),r=W(e),i=null==(t=e.ownerDocument)?void 0:t.body,s=B(n.scrollWidth,n.clientWidth,i?i.scrollWidth:0,i?i.clientWidth:0),o=B(n.scrollHeight,n.clientHeight,i?i.scrollHeight:0,i?i.clientHeight:0),a=-r.scrollLeft+H(e),c=-r.scrollTop;return"rtl"===A(i||n).direction&&(a+=B(n.clientWidth,i?i.clientWidth:0)-s),{width:s,height:o,x:a,y:c}}(k(e)))}function Q(e,t,n){var r="clippingParents"===t?function(e){var t=Y(C(e)),n=["absolute","fixed"].indexOf(A(e).position)>=0&&m(e)?M(e):e;return g(n)?t.filter((function(e){return g(e)&&O(e,n)&&"body"!==p(e)})):[]}(e):[].concat(t),i=[].concat(r,[n]),s=i[0],o=i.reduce((function(t,n){var r=X(e,n);return t.top=B(r.top,t.top),t.right=N(r.right,t.right),t.bottom=N(r.bottom,t.bottom),t.left=B(r.left,t.left),t}),X(e,s));return o.width=o.right-o.left,o.height=o.bottom-o.top,o.x=o.left,o.y=o.top,o}function G(e){return e.split("-")[1]}function Z(i){var s,c=i.reference,l=i.element,u=i.placement,h=u?y(u):null,d=u?G(u):null,p=c.x+c.width/2-l.width/2,f=c.y+c.height/2-l.height/2;switch(h){case e:s={x:p,y:c.y-l.height};break;case t:s={x:p,y:c.y+c.height};break;case n:s={x:c.x+c.width,y:f};break;case r:s={x:c.x-l.width,y:f};break;default:s={x:c.x,y:c.y}}var g=h?D(h):null;if(null!=g){var m="y"===g?"height":"width";switch(d){case o:s[g]=s[g]-(c[m]/2-l[m]/2);break;case a:s[g]=s[g]+(c[m]/2-l[m]/2)}}return s}function ee(r,i){void 0===i&&(i={});var o=i,a=o.placement,u=void 0===a?r.placement:a,h=o.boundary,d=void 0===h?"clippingParents":h,p=o.rootBoundary,f=void 0===p?c:p,m=o.elementContext,v=void 0===m?l:m,b=o.altBoundary,y=void 0!==b&&b,w=o.padding,E=void 0===w?0:w,O=I("number"!=typeof E?E:V(E,s)),A=v===l?"reference":l,x=r.elements.reference,C=r.rects.popper,L=r.elements[y?A:v],M=Q(g(L)?L:L.contextElement||k(r.elements.popper),d,f),D=T(x),B=Z({reference:D,element:C,strategy:"absolute",placement:u}),N=J(Object.assign({},C,B)),S=v===l?N:D,j={top:M.top-S.top+O.top,bottom:S.bottom-M.bottom+O.bottom,left:M.left-S.left+O.left,right:S.right-M.right+O.right},F=r.modifiersData.offset;if(v===l&&F){var $=F[u];Object.keys(j).forEach((function(r){var i=[n,t].indexOf(r)>=0?1:-1,s=[e,t].indexOf(r)>=0?"y":"x";j[r]+=$[s]*i}))}return j}function te(e,t){void 0===t&&(t={});var n=t,r=n.placement,i=n.boundary,o=n.rootBoundary,a=n.padding,c=n.flipVariations,l=n.allowedAutoPlacements,d=void 0===l?h:l,p=G(r),f=p?c?u:u.filter((function(e){return G(e)===p})):s,g=f.filter((function(e){return d.indexOf(e)>=0}));0===g.length&&(g=f);var m=g.reduce((function(t,n){return t[n]=ee(e,{placement:n,boundary:i,rootBoundary:o,padding:a})[y(n)],t}),{});return Object.keys(m).sort((function(e,t){return m[e]-m[t]}))}function ne(e,t,n){return void 0===n&&(n={x:0,y:0}),{top:e.top-t.height-n.y,right:e.right-t.width+n.x,bottom:e.bottom-t.height+n.y,left:e.left-t.width-n.x}}function re(i){return[e,n,t,r].some((function(e){return i[e]>=0}))}function ie(e,t,n){void 0===n&&(n=!1);var r,i,s=m(t),o=m(t)&&function(e){var t=e.getBoundingClientRect(),n=t.width/e.offsetWidth||1,r=t.height/e.offsetHeight||1;return 1!==n||1!==r}(t),a=k(t),c=T(e,o),l={scrollLeft:0,scrollTop:0},u={x:0,y:0};return(s||!s&&!n)&&(("body"!==p(t)||q(a))&&(l=(r=t)!==f(r)&&m(r)?{scrollLeft:(i=r).scrollLeft,scrollTop:i.scrollTop}:W(r)),m(t)?((u=T(t,!0)).x+=t.clientLeft,u.y+=t.clientTop):a&&(u.x=H(a))),{x:c.left+l.scrollLeft-u.x,y:c.top+l.scrollTop-u.y,width:c.width,height:c.height}}function se(e){var t=new Map,n=new Set,r=[];function i(e){n.add(e.name),[].concat(e.requires||[],e.requiresIfExists||[]).forEach((function(e){if(!n.has(e)){var r=t.get(e);r&&i(r)}})),r.push(e)}return e.forEach((function(e){t.set(e.name,e)})),e.forEach((function(e){n.has(e.name)||i(e)})),r}var oe={placement:"bottom",modifiers:[],strategy:"absolute"};function ae(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return!t.some((function(e){return!(e&&"function"==typeof e.getBoundingClientRect)}))}function ce(e){void 0===e&&(e={});var t=e,n=t.defaultModifiers,r=void 0===n?[]:n,i=t.defaultOptions,s=void 0===i?oe:i;return function(e,t,n){void 0===n&&(n=s);var i,o,a={placement:"bottom",orderedModifiers:[],options:Object.assign({},oe,s),modifiersData:{},elements:{reference:e,popper:t},attributes:{},styles:{}},c=[],l=!1,u={state:a,setOptions:function(n){h(),a.options=Object.assign({},s,a.options,n),a.scrollParents={reference:g(e)?Y(e):e.contextElement?Y(e.contextElement):[],popper:Y(t)};var i,o,l=function(e){var t=se(e);return d.reduce((function(e,n){return e.concat(t.filter((function(e){return e.phase===n})))}),[])}((i=[].concat(r,a.options.modifiers),o=i.reduce((function(e,t){var n=e[t.name];return e[t.name]=n?Object.assign({},n,t,{options:Object.assign({},n.options,t.options),data:Object.assign({},n.data,t.data)}):t,e}),{}),Object.keys(o).map((function(e){return o[e]}))));return a.orderedModifiers=l.filter((function(e){return e.enabled})),a.orderedModifiers.forEach((function(e){var t=e.name,n=e.options,r=void 0===n?{}:n,i=e.effect;if("function"==typeof i){var s=i({state:a,name:t,instance:u,options:r}),o=function(){};c.push(s||o)}})),u.update()},forceUpdate:function(){if(!l){var e=a.elements,t=e.reference,n=e.popper;if(ae(t,n)){a.rects={reference:ie(t,M(n),"fixed"===a.options.strategy),popper:E(n)},a.reset=!1,a.placement=a.options.placement,a.orderedModifiers.forEach((function(e){return a.modifiersData[e.name]=Object.assign({},e.data)}));for(var r=0;r<a.orderedModifiers.length;r++)if(!0!==a.reset){var i=a.orderedModifiers[r],s=i.fn,o=i.options,c=void 0===o?{}:o,h=i.name;"function"==typeof s&&(a=s({state:a,options:c,name:h,instance:u})||a)}else a.reset=!1,r=-1}}},update:(i=function(){return new Promise((function(e){u.forceUpdate(),e(a)}))},function(){return o||(o=new Promise((function(e){Promise.resolve().then((function(){o=void 0,e(i())}))}))),o}),destroy:function(){h(),l=!0}};if(!ae(e,t))return u;function h(){c.forEach((function(e){return e()})),c=[]}return u.setOptions(n).then((function(e){!l&&n.onFirstUpdate&&n.onFirstUpdate(e)})),u}}var le=ce({defaultModifiers:[{name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:function(e){var t=e.state,n=e.instance,r=e.options,i=r.scroll,s=void 0===i||i,o=r.resize,a=void 0===o||o,c=f(t.elements.popper),l=[].concat(t.scrollParents.reference,t.scrollParents.popper);return s&&l.forEach((function(e){e.addEventListener("scroll",n.update,_)})),a&&c.addEventListener("resize",n.update,_),function(){s&&l.forEach((function(e){e.removeEventListener("scroll",n.update,_)})),a&&c.removeEventListener("resize",n.update,_)}},data:{}},{name:"popperOffsets",enabled:!0,phase:"read",fn:function(e){var t=e.state,n=e.name;t.modifiersData[n]=Z({reference:t.rects.reference,element:t.rects.popper,strategy:"absolute",placement:t.placement})},data:{}},{name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:function(e){var t=e.state,n=e.options,r=n.gpuAcceleration,i=void 0===r||r,s=n.adaptive,o=void 0===s||s,a=n.roundOffsets,c=void 0===a||a,l={placement:y(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:i};null!=t.modifiersData.popperOffsets&&(t.styles.popper=Object.assign({},t.styles.popper,$(Object.assign({},l,{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:o,roundOffsets:c})))),null!=t.modifiersData.arrow&&(t.styles.arrow=Object.assign({},t.styles.arrow,$(Object.assign({},l,{offsets:t.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:c})))),t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-placement":t.placement})},data:{}},b,{name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:function(t){var i=t.state,s=t.options,o=t.name,a=s.offset,c=void 0===a?[0,0]:a,l=h.reduce((function(t,s){return t[s]=function(t,i,s){var o=y(t),a=[r,e].indexOf(o)>=0?-1:1,c="function"==typeof s?s(Object.assign({},i,{placement:t})):s,l=c[0],u=c[1];return l=l||0,u=(u||0)*a,[r,n].indexOf(o)>=0?{x:u,y:l}:{x:l,y:u}}(s,i.rects,c),t}),{}),u=l[i.placement],d=u.x,p=u.y;null!=i.modifiersData.popperOffsets&&(i.modifiersData.popperOffsets.x+=d,i.modifiersData.popperOffsets.y+=p),i.modifiersData[o]=l}},{name:"flip",enabled:!0,phase:"main",fn:function(s){var a=s.state,c=s.options,l=s.name;if(!a.modifiersData[l]._skip){for(var u=c.mainAxis,h=void 0===u||u,d=c.altAxis,p=void 0===d||d,f=c.fallbackPlacements,g=c.padding,m=c.boundary,v=c.rootBoundary,b=c.altBoundary,w=c.flipVariations,T=void 0===w||w,E=c.allowedAutoPlacements,O=a.options.placement,A=y(O),x=f||(A===O||!T?[R(O)]:function(e){if(y(e)===i)return[];var t=R(e);return[U(e),t,U(t)]}(O)),k=[O].concat(x).reduce((function(e,t){return e.concat(y(t)===i?te(a,{placement:t,boundary:m,rootBoundary:v,padding:g,flipVariations:T,allowedAutoPlacements:E}):t)}),[]),C=a.rects.reference,L=a.rects.popper,M=new Map,D=!0,B=k[0],N=0;N<k.length;N++){var S=k[N],j=y(S),I=G(S)===o,V=[e,t].indexOf(j)>=0,F=V?"width":"height",$=ee(a,{placement:S,boundary:m,rootBoundary:v,altBoundary:b,padding:g}),_=V?I?n:r:I?t:e;C[F]>L[F]&&(_=R(_));var P=R(_),K=[];if(h&&K.push($[j]<=0),p&&K.push($[_]<=0,$[P]<=0),K.every((function(e){return e}))){B=S,D=!1;break}M.set(S,K)}if(D)for(var W=function(e){var t=k.find((function(t){var n=M.get(t);if(n)return n.slice(0,e).every((function(e){return e}))}));if(t)return B=t,"break"},H=T?3:1;H>0;H--){if("break"===W(H))break}a.placement!==B&&(a.modifiersData[l]._skip=!0,a.placement=B,a.reset=!0)}},requiresIfExists:["offset"],data:{_skip:!1}},{name:"preventOverflow",enabled:!0,phase:"main",fn:function(i){var s=i.state,a=i.options,c=i.name,l=a.mainAxis,u=void 0===l||l,h=a.altAxis,d=void 0!==h&&h,p=a.boundary,f=a.rootBoundary,g=a.altBoundary,m=a.padding,v=a.tether,b=void 0===v||v,w=a.tetherOffset,T=void 0===w?0:w,O=ee(s,{boundary:p,rootBoundary:f,padding:m,altBoundary:g}),A=y(s.placement),x=G(s.placement),k=!x,C=D(A),L="x"===C?"y":"x",S=s.modifiersData.popperOffsets,I=s.rects.reference,V=s.rects.popper,F="function"==typeof T?T(Object.assign({},s.rects,{placement:s.placement})):T,$={x:0,y:0};if(S){if(u||d){var _="y"===C?e:r,P="y"===C?t:n,R="y"===C?"height":"width",K=S[C],U=S[C]+O[_],W=S[C]-O[P],H=b?-V[R]/2:0,q=x===o?I[R]:V[R],z=x===o?-V[R]:-I[R],Y=s.elements.arrow,J=b&&Y?E(Y):{width:0,height:0},X=s.modifiersData["arrow#persistent"]?s.modifiersData["arrow#persistent"].padding:{top:0,right:0,bottom:0,left:0},Q=X[_],Z=X[P],te=j(0,I[R],J[R]),ne=k?I[R]/2-H-te-Q-F:q-te-Q-F,re=k?-I[R]/2+H+te+Z+F:z+te+Z+F,ie=s.elements.arrow&&M(s.elements.arrow),se=ie?"y"===C?ie.clientTop||0:ie.clientLeft||0:0,oe=s.modifiersData.offset?s.modifiersData.offset[s.placement][C]:0,ae=S[C]+ne-oe-se,ce=S[C]+re-oe;if(u){var le=j(b?N(U,ae):U,K,b?B(W,ce):W);S[C]=le,$[C]=le-K}if(d){var ue="x"===C?e:r,he="x"===C?t:n,de=S[L],pe=de+O[ue],fe=de-O[he],ge=j(b?N(pe,ae):pe,de,b?B(fe,ce):fe);S[L]=ge,$[L]=ge-de}}s.modifiersData[c]=$}},requiresIfExists:["offset"]},{name:"arrow",enabled:!0,phase:"main",fn:function(i){var o,a=i.state,c=i.name,l=i.options,u=a.elements.arrow,h=a.modifiersData.popperOffsets,d=y(a.placement),p=D(d),f=[r,n].indexOf(d)>=0?"height":"width";if(u&&h){var g=function(e,t){return I("number"!=typeof(e="function"==typeof e?e(Object.assign({},t.rects,{placement:t.placement})):e)?e:V(e,s))}(l.padding,a),m=E(u),v="y"===p?e:r,b="y"===p?t:n,w=a.rects.reference[f]+a.rects.reference[p]-h[p]-a.rects.popper[f],T=h[p]-a.rects.reference[p],O=M(u),A=O?"y"===p?O.clientHeight||0:O.clientWidth||0:0,x=w/2-T/2,k=g[v],C=A-m[f]-g[b],L=A/2-m[f]/2+x,B=j(k,L,C),N=p;a.modifiersData[c]=((o={})[N]=B,o.centerOffset=B-L,o)}},effect:function(e){var t=e.state,n=e.options.element,r=void 0===n?"[data-popper-arrow]":n;null!=r&&("string"!=typeof r||(r=t.elements.popper.querySelector(r)))&&O(t.elements.popper,r)&&(t.elements.arrow=r)},requires:["popperOffsets"],requiresIfExists:["preventOverflow"]},{name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:function(e){var t=e.state,n=e.name,r=t.rects.reference,i=t.rects.popper,s=t.modifiersData.preventOverflow,o=ee(t,{elementContext:"reference"}),a=ee(t,{altBoundary:!0}),c=ne(o,r),l=ne(a,i,s),u=re(c),h=re(l);t.modifiersData[n]={referenceClippingOffsets:c,popperEscapeOffsets:l,isReferenceHidden:u,hasPopperEscaped:h},t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-reference-hidden":u,"data-popper-escaped":h})}}]}),ue="tippy-content",he="tippy-arrow",de="tippy-svg-arrow",pe={passive:!0,capture:!0};function fe(e,t,n){if(Array.isArray(e)){var r=e[t];return null==r?Array.isArray(n)?n[t]:n:r}return e}function ge(e,t){var n={}.toString.call(e);return 0===n.indexOf("[object")&&n.indexOf(t+"]")>-1}function me(e,t){return"function"==typeof e?e.apply(void 0,t):e}function ve(e,t){return 0===t?e:function(r){clearTimeout(n),n=setTimeout((function(){e(r)}),t)};var n}function be(e){return[].concat(e)}function ye(e,t){-1===e.indexOf(t)&&e.push(t)}function we(e){return[].slice.call(e)}function Te(){return document.createElement("div")}function Ee(e){return["Element","Fragment"].some((function(t){return ge(e,t)}))}function Oe(e){return Ee(e)?[e]:function(e){return ge(e,"NodeList")}(e)?we(e):Array.isArray(e)?e:we(document.querySelectorAll(e))}function Ae(e,t){e.forEach((function(e){e&&(e.style.transitionDuration=t+"ms")}))}function xe(e,t){e.forEach((function(e){e&&e.setAttribute("data-state",t)}))}function ke(e,t,n){var r=t+"EventListener";["transitionend","webkitTransitionEnd"].forEach((function(t){e[r](t,n)}))}var Ce={isTouch:!1},Le=0;function Me(){Ce.isTouch||(Ce.isTouch=!0,window.performance&&document.addEventListener("mousemove",De))}function De(){var e=performance.now();e-Le<20&&(Ce.isTouch=!1,document.removeEventListener("mousemove",De)),Le=e}function Be(){var e,t=document.activeElement;if((e=t)&&e._tippy&&e._tippy.reference===e){var n=t._tippy;t.blur&&!n.state.isVisible&&t.blur()}}var Ne="undefined"!=typeof window&&"undefined"!=typeof document?navigator.userAgent:"",Se=/MSIE |Trident\//.test(Ne),je=Object.assign({appendTo:function(){return document.body},aria:{content:"auto",expanded:"auto"},delay:0,duration:[300,250],getReferenceClientRect:null,hideOnClick:!0,ignoreAttributes:!1,interactive:!1,interactiveBorder:2,interactiveDebounce:0,moveTransition:"",offset:[0,10],onAfterUpdate:function(){},onBeforeUpdate:function(){},onCreate:function(){},onDestroy:function(){},onHidden:function(){},onHide:function(){},onMount:function(){},onShow:function(){},onShown:function(){},onTrigger:function(){},onUntrigger:function(){},onClickOutside:function(){},placement:"top",plugins:[],popperOptions:{},render:null,showOnCreate:!1,touch:!0,trigger:"mouseenter focus",triggerTarget:null},{animateFill:!1,followCursor:!1,inlinePositioning:!1,sticky:!1},{},{allowHTML:!1,animation:"fade",arrow:!0,content:"",inertia:!1,maxWidth:350,role:"tooltip",theme:"",zIndex:9999}),Ie=Object.keys(je);function Ve(e){var t=(e.plugins||[]).reduce((function(t,n){var r=n.name,i=n.defaultValue;return r&&(t[r]=void 0!==e[r]?e[r]:i),t}),{});return Object.assign({},e,{},t)}function Fe(e,t){var n=Object.assign({},t,{content:me(t.content,[e])},t.ignoreAttributes?{}:function(e,t){return(t?Object.keys(Ve(Object.assign({},je,{plugins:t}))):Ie).reduce((function(t,n){var r=(e.getAttribute("data-tippy-"+n)||"").trim();if(!r)return t;if("content"===n)t[n]=r;else try{t[n]=JSON.parse(r)}catch(e){t[n]=r}return t}),{})}(e,t.plugins));return n.aria=Object.assign({},je.aria,{},n.aria),n.aria={expanded:"auto"===n.aria.expanded?t.interactive:n.aria.expanded,content:"auto"===n.aria.content?t.interactive?null:"describedby":n.aria.content},n}function $e(e,t){e.innerHTML=t}function _e(e){var t=Te();return!0===e?t.className=he:(t.className=de,Ee(e)?t.appendChild(e):$e(t,e)),t}function Pe(e,t){Ee(t.content)?($e(e,""),e.appendChild(t.content)):"function"!=typeof t.content&&(t.allowHTML?$e(e,t.content):e.textContent=t.content)}function Re(e){var t=e.firstElementChild,n=we(t.children);return{box:t,content:n.find((function(e){return e.classList.contains(ue)})),arrow:n.find((function(e){return e.classList.contains(he)||e.classList.contains(de)})),backdrop:n.find((function(e){return e.classList.contains("tippy-backdrop")}))}}function Ke(e){var t=Te(),n=Te();n.className="tippy-box",n.setAttribute("data-state","hidden"),n.setAttribute("tabindex","-1");var r=Te();function i(n,r){var i=Re(t),s=i.box,o=i.content,a=i.arrow;r.theme?s.setAttribute("data-theme",r.theme):s.removeAttribute("data-theme"),"string"==typeof r.animation?s.setAttribute("data-animation",r.animation):s.removeAttribute("data-animation"),r.inertia?s.setAttribute("data-inertia",""):s.removeAttribute("data-inertia"),s.style.maxWidth="number"==typeof r.maxWidth?r.maxWidth+"px":r.maxWidth,r.role?s.setAttribute("role",r.role):s.removeAttribute("role"),n.content===r.content&&n.allowHTML===r.allowHTML||Pe(o,e.props),r.arrow?a?n.arrow!==r.arrow&&(s.removeChild(a),s.appendChild(_e(r.arrow))):s.appendChild(_e(r.arrow)):a&&s.removeChild(a)}return r.className=ue,r.setAttribute("data-state","hidden"),Pe(r,e.props),t.appendChild(n),n.appendChild(r),i(e.props,e.props),{popper:t,onUpdate:i}}Ke.$$tippy=!0;var Ue=1,We=[],He=[];function qe(e,t){var n,r,i,s,o,a,c,l,u,h=Fe(e,Object.assign({},je,{},Ve((n=t,Object.keys(n).reduce((function(e,t){return void 0!==n[t]&&(e[t]=n[t]),e}),{}))))),d=!1,p=!1,f=!1,g=!1,m=[],v=ve(Y,h.interactiveDebounce),b=Ue++,y=(u=h.plugins).filter((function(e,t){return u.indexOf(e)===t})),w={id:b,reference:e,popper:Te(),popperInstance:null,props:h,state:{isEnabled:!0,isVisible:!1,isDestroyed:!1,isMounted:!1,isShown:!1},plugins:y,clearDelayTimeouts:function(){clearTimeout(r),clearTimeout(i),cancelAnimationFrame(s)},setProps:function(t){if(w.state.isDestroyed)return;j("onBeforeUpdate",[w,t]),q();var n=w.props,r=Fe(e,Object.assign({},w.props,{},t,{ignoreAttributes:!0}));w.props=r,H(),n.interactiveDebounce!==r.interactiveDebounce&&(F(),v=ve(Y,r.interactiveDebounce));n.triggerTarget&&!r.triggerTarget?be(n.triggerTarget).forEach((function(e){e.removeAttribute("aria-expanded")})):r.triggerTarget&&e.removeAttribute("aria-expanded");V(),S(),O&&O(n,r);w.popperInstance&&(G(),ee().forEach((function(e){requestAnimationFrame(e._tippy.popperInstance.forceUpdate)})));j("onAfterUpdate",[w,t])},setContent:function(e){w.setProps({content:e})},show:function(){var e=w.state.isVisible,t=w.state.isDestroyed,n=!w.state.isEnabled,r=Ce.isTouch&&!w.props.touch,i=fe(w.props.duration,0,je.duration);if(e||t||n||r)return;if(M().hasAttribute("disabled"))return;if(j("onShow",[w],!1),!1===w.props.onShow(w))return;w.state.isVisible=!0,L()&&(E.style.visibility="visible");S(),R(),w.state.isMounted||(E.style.transition="none");if(L()){var s=B(),o=s.box,a=s.content;Ae([o,a],0)}c=function(){var e;if(w.state.isVisible&&!g){if(g=!0,E.offsetHeight,E.style.transition=w.props.moveTransition,L()&&w.props.animation){var t=B(),n=t.box,r=t.content;Ae([n,r],i),xe([n,r],"visible")}I(),V(),ye(He,w),null==(e=w.popperInstance)||e.forceUpdate(),w.state.isMounted=!0,j("onMount",[w]),w.props.animation&&L()&&function(e,t){U(e,t)}(i,(function(){w.state.isShown=!0,j("onShown",[w])}))}},function(){var e,t=w.props.appendTo,n=M();e=w.props.interactive&&t===je.appendTo||"parent"===t?n.parentNode:me(t,[n]);e.contains(E)||e.appendChild(E);G()}()},hide:function(){var e=!w.state.isVisible,t=w.state.isDestroyed,n=!w.state.isEnabled,r=fe(w.props.duration,1,je.duration);if(e||t||n)return;if(j("onHide",[w],!1),!1===w.props.onHide(w))return;w.state.isVisible=!1,w.state.isShown=!1,g=!1,d=!1,L()&&(E.style.visibility="hidden");if(F(),K(),S(),L()){var i=B(),s=i.box,o=i.content;w.props.animation&&(Ae([s,o],r),xe([s,o],"hidden"))}I(),V(),w.props.animation?L()&&function(e,t){U(e,(function(){!w.state.isVisible&&E.parentNode&&E.parentNode.contains(E)&&t()}))}(r,w.unmount):w.unmount()},hideWithInteractivity:function(e){D().addEventListener("mousemove",v),ye(We,v),v(e)},enable:function(){w.state.isEnabled=!0},disable:function(){w.hide(),w.state.isEnabled=!1},unmount:function(){w.state.isVisible&&w.hide();if(!w.state.isMounted)return;Z(),ee().forEach((function(e){e._tippy.unmount()})),E.parentNode&&E.parentNode.removeChild(E);He=He.filter((function(e){return e!==w})),w.state.isMounted=!1,j("onHidden",[w])},destroy:function(){if(w.state.isDestroyed)return;w.clearDelayTimeouts(),w.unmount(),q(),delete e._tippy,w.state.isDestroyed=!0,j("onDestroy",[w])}};if(!h.render)return w;var T=h.render(w),E=T.popper,O=T.onUpdate;E.setAttribute("data-tippy-root",""),E.id="tippy-"+w.id,w.popper=E,e._tippy=w,E._tippy=w;var A=y.map((function(e){return e.fn(w)})),x=e.hasAttribute("aria-expanded");return H(),V(),S(),j("onCreate",[w]),h.showOnCreate&&te(),E.addEventListener("mouseenter",(function(){w.props.interactive&&w.state.isVisible&&w.clearDelayTimeouts()})),E.addEventListener("mouseleave",(function(e){w.props.interactive&&w.props.trigger.indexOf("mouseenter")>=0&&(D().addEventListener("mousemove",v),v(e))})),w;function k(){var e=w.props.touch;return Array.isArray(e)?e:[e,0]}function C(){return"hold"===k()[0]}function L(){var e;return!!(null==(e=w.props.render)?void 0:e.$$tippy)}function M(){return l||e}function D(){var e,t,n=M().parentNode;return n?(null==(t=be(n)[0])||null==(e=t.ownerDocument)?void 0:e.body)?t.ownerDocument:document:document}function B(){return Re(E)}function N(e){return w.state.isMounted&&!w.state.isVisible||Ce.isTouch||o&&"focus"===o.type?0:fe(w.props.delay,e?0:1,je.delay)}function S(){E.style.pointerEvents=w.props.interactive&&w.state.isVisible?"":"none",E.style.zIndex=""+w.props.zIndex}function j(e,t,n){var r;(void 0===n&&(n=!0),A.forEach((function(n){n[e]&&n[e].apply(void 0,t)})),n)&&(r=w.props)[e].apply(r,t)}function I(){var t=w.props.aria;if(t.content){var n="aria-"+t.content,r=E.id;be(w.props.triggerTarget||e).forEach((function(e){var t=e.getAttribute(n);if(w.state.isVisible)e.setAttribute(n,t?t+" "+r:r);else{var i=t&&t.replace(r,"").trim();i?e.setAttribute(n,i):e.removeAttribute(n)}}))}}function V(){!x&&w.props.aria.expanded&&be(w.props.triggerTarget||e).forEach((function(e){w.props.interactive?e.setAttribute("aria-expanded",w.state.isVisible&&e===M()?"true":"false"):e.removeAttribute("aria-expanded")}))}function F(){D().removeEventListener("mousemove",v),We=We.filter((function(e){return e!==v}))}function $(e){if(!(Ce.isTouch&&(f||"mousedown"===e.type)||w.props.interactive&&E.contains(e.target))){if(M().contains(e.target)){if(Ce.isTouch)return;if(w.state.isVisible&&w.props.trigger.indexOf("click")>=0)return}else j("onClickOutside",[w,e]);!0===w.props.hideOnClick&&(w.clearDelayTimeouts(),w.hide(),p=!0,setTimeout((function(){p=!1})),w.state.isMounted||K())}}function _(){f=!0}function P(){f=!1}function R(){var e=D();e.addEventListener("mousedown",$,!0),e.addEventListener("touchend",$,pe),e.addEventListener("touchstart",P,pe),e.addEventListener("touchmove",_,pe)}function K(){var e=D();e.removeEventListener("mousedown",$,!0),e.removeEventListener("touchend",$,pe),e.removeEventListener("touchstart",P,pe),e.removeEventListener("touchmove",_,pe)}function U(e,t){var n=B().box;function r(e){e.target===n&&(ke(n,"remove",r),t())}if(0===e)return t();ke(n,"remove",a),ke(n,"add",r),a=r}function W(t,n,r){void 0===r&&(r=!1),be(w.props.triggerTarget||e).forEach((function(e){e.addEventListener(t,n,r),m.push({node:e,eventType:t,handler:n,options:r})}))}function H(){var e;C()&&(W("touchstart",z,{passive:!0}),W("touchend",J,{passive:!0})),(e=w.props.trigger,e.split(/\s+/).filter(Boolean)).forEach((function(e){if("manual"!==e)switch(W(e,z),e){case"mouseenter":W("mouseleave",J);break;case"focus":W(Se?"focusout":"blur",X);break;case"focusin":W("focusout",X)}}))}function q(){m.forEach((function(e){var t=e.node,n=e.eventType,r=e.handler,i=e.options;t.removeEventListener(n,r,i)})),m=[]}function z(e){var t,n=!1;if(w.state.isEnabled&&!Q(e)&&!p){var r="focus"===(null==(t=o)?void 0:t.type);o=e,l=e.currentTarget,V(),!w.state.isVisible&&ge(e,"MouseEvent")&&We.forEach((function(t){return t(e)})),"click"===e.type&&(w.props.trigger.indexOf("mouseenter")<0||d)&&!1!==w.props.hideOnClick&&w.state.isVisible?n=!0:te(e),"click"===e.type&&(d=!n),n&&!r&&ne(e)}}function Y(e){var t=e.target,n=M().contains(t)||E.contains(t);"mousemove"===e.type&&n||function(e,t){var n=t.clientX,r=t.clientY;return e.every((function(e){var t=e.popperRect,i=e.popperState,s=e.props.interactiveBorder,o=i.placement.split("-")[0],a=i.modifiersData.offset;if(!a)return!0;var c="bottom"===o?a.top.y:0,l="top"===o?a.bottom.y:0,u="right"===o?a.left.x:0,h="left"===o?a.right.x:0,d=t.top-r+c>s,p=r-t.bottom-l>s,f=t.left-n+u>s,g=n-t.right-h>s;return d||p||f||g}))}(ee().concat(E).map((function(e){var t,n=null==(t=e._tippy.popperInstance)?void 0:t.state;return n?{popperRect:e.getBoundingClientRect(),popperState:n,props:h}:null})).filter(Boolean),e)&&(F(),ne(e))}function J(e){Q(e)||w.props.trigger.indexOf("click")>=0&&d||(w.props.interactive?w.hideWithInteractivity(e):ne(e))}function X(e){w.props.trigger.indexOf("focusin")<0&&e.target!==M()||w.props.interactive&&e.relatedTarget&&E.contains(e.relatedTarget)||ne(e)}function Q(e){return!!Ce.isTouch&&C()!==e.type.indexOf("touch")>=0}function G(){Z();var t=w.props,n=t.popperOptions,r=t.placement,i=t.offset,s=t.getReferenceClientRect,o=t.moveTransition,a=L()?Re(E).arrow:null,l=s?{getBoundingClientRect:s,contextElement:s.contextElement||M()}:e,u=[{name:"offset",options:{offset:i}},{name:"preventOverflow",options:{padding:{top:2,bottom:2,left:5,right:5}}},{name:"flip",options:{padding:5}},{name:"computeStyles",options:{adaptive:!o}},{name:"$$tippy",enabled:!0,phase:"beforeWrite",requires:["computeStyles"],fn:function(e){var t=e.state;if(L()){var n=B().box;["placement","reference-hidden","escaped"].forEach((function(e){"placement"===e?n.setAttribute("data-placement",t.placement):t.attributes.popper["data-popper-"+e]?n.setAttribute("data-"+e,""):n.removeAttribute("data-"+e)})),t.attributes.popper={}}}}];L()&&a&&u.push({name:"arrow",options:{element:a,padding:3}}),u.push.apply(u,(null==n?void 0:n.modifiers)||[]),w.popperInstance=le(l,E,Object.assign({},n,{placement:r,onFirstUpdate:c,modifiers:u}))}function Z(){w.popperInstance&&(w.popperInstance.destroy(),w.popperInstance=null)}function ee(){return we(E.querySelectorAll("[data-tippy-root]"))}function te(e){w.clearDelayTimeouts(),e&&j("onTrigger",[w,e]),R();var t=N(!0),n=k(),i=n[0],s=n[1];Ce.isTouch&&"hold"===i&&s&&(t=s),t?r=setTimeout((function(){w.show()}),t):w.show()}function ne(e){if(w.clearDelayTimeouts(),j("onUntrigger",[w,e]),w.state.isVisible){if(!(w.props.trigger.indexOf("mouseenter")>=0&&w.props.trigger.indexOf("click")>=0&&["mouseleave","mousemove"].indexOf(e.type)>=0&&d)){var t=N(!1);t?i=setTimeout((function(){w.state.isVisible&&w.hide()}),t):s=requestAnimationFrame((function(){w.hide()}))}}else K()}}function ze(e,t){void 0===t&&(t={});var n=je.plugins.concat(t.plugins||[]);document.addEventListener("touchstart",Me,pe),window.addEventListener("blur",Be);var r=Object.assign({},t,{plugins:n}),i=Oe(e).reduce((function(e,t){var n=t&&qe(t,r);return n&&e.push(n),e}),[]);return Ee(e)?i[0]:i}ze.defaultProps=je,ze.setDefaultProps=function(e){Object.keys(e).forEach((function(t){je[t]=e[t]}))},ze.currentInput=Ce,Object.assign({},b,{effect:function(e){var t=e.state,n={popper:{position:t.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};Object.assign(t.elements.popper.style,n.popper),t.styles=n,t.elements.arrow&&Object.assign(t.elements.arrow.style,n.arrow)}}),ze.setDefaultProps({render:Ke});class Ye{constructor(e,t,n){this.eventTarget=e,this.eventName=t,this.eventOptions=n,this.unorderedBindings=new Set}connect(){this.eventTarget.addEventListener(this.eventName,this,this.eventOptions)}disconnect(){this.eventTarget.removeEventListener(this.eventName,this,this.eventOptions)}bindingConnected(e){this.unorderedBindings.add(e)}bindingDisconnected(e){this.unorderedBindings.delete(e)}handleEvent(e){const t=function(e){if("immediatePropagationStopped"in e)return e;{const{stopImmediatePropagation:t}=e;return Object.assign(e,{immediatePropagationStopped:!1,stopImmediatePropagation(){this.immediatePropagationStopped=!0,t.call(this)}})}}(e);for(const e of this.bindings){if(t.immediatePropagationStopped)break;e.handleEvent(t)}}get bindings(){return Array.from(this.unorderedBindings).sort(((e,t)=>{const n=e.index,r=t.index;return n<r?-1:n>r?1:0}))}}class Je{constructor(e){this.application=e,this.eventListenerMaps=new Map,this.started=!1}start(){this.started||(this.started=!0,this.eventListeners.forEach((e=>e.connect())))}stop(){this.started&&(this.started=!1,this.eventListeners.forEach((e=>e.disconnect())))}get eventListeners(){return Array.from(this.eventListenerMaps.values()).reduce(((e,t)=>e.concat(Array.from(t.values()))),[])}bindingConnected(e){this.fetchEventListenerForBinding(e).bindingConnected(e)}bindingDisconnected(e){this.fetchEventListenerForBinding(e).bindingDisconnected(e)}handleError(e,t,n={}){this.application.handleError(e,`Error ${t}`,n)}fetchEventListenerForBinding(e){const{eventTarget:t,eventName:n,eventOptions:r}=e;return this.fetchEventListener(t,n,r)}fetchEventListener(e,t,n){const r=this.fetchEventListenerMapForEventTarget(e),i=this.cacheKey(t,n);let s=r.get(i);return s||(s=this.createEventListener(e,t,n),r.set(i,s)),s}createEventListener(e,t,n){const r=new Ye(e,t,n);return this.started&&r.connect(),r}fetchEventListenerMapForEventTarget(e){let t=this.eventListenerMaps.get(e);return t||(t=new Map,this.eventListenerMaps.set(e,t)),t}cacheKey(e,t){const n=[e];return Object.keys(t).sort().forEach((e=>{n.push(`${t[e]?"":"!"}${e}`)})),n.join(":")}}const Xe=/^((.+?)(@(window|document))?->)?(.+?)(#([^:]+?))(:(.+))?$/;function Qe(e){return"window"==e?window:"document"==e?document:void 0}function Ge(e){return e.replace(/(?:[_-])([a-z0-9])/g,((e,t)=>t.toUpperCase()))}function Ze(e){return e.charAt(0).toUpperCase()+e.slice(1)}function et(e){return e.replace(/([A-Z])/g,((e,t)=>`-${t.toLowerCase()}`))}const tt={a:e=>"click",button:e=>"click",form:e=>"submit",details:e=>"toggle",input:e=>"submit"==e.getAttribute("type")?"click":"input",select:e=>"change",textarea:e=>"input"};function nt(e){throw new Error(e)}function rt(e){try{return JSON.parse(e)}catch(t){return e}}class it{constructor(e,t){this.context=e,this.action=t}get index(){return this.action.index}get eventTarget(){return this.action.eventTarget}get eventOptions(){return this.action.eventOptions}get identifier(){return this.context.identifier}handleEvent(e){this.willBeInvokedByEvent(e)&&this.invokeWithEvent(e)}get eventName(){return this.action.eventName}get method(){const e=this.controller[this.methodName];if("function"==typeof e)return e;throw new Error(`Action "${this.action}" references undefined method "${this.methodName}"`)}invokeWithEvent(e){const{target:t,currentTarget:n}=e;try{const{params:r}=this.action,i=Object.assign(e,{params:r});this.method.call(this.controller,i),this.context.logDebugActivity(this.methodName,{event:e,target:t,currentTarget:n,action:this.methodName})}catch(t){const{identifier:n,controller:r,element:i,index:s}=this,o={identifier:n,controller:r,element:i,index:s,event:e};this.context.handleError(t,`invoking action "${this.action}"`,o)}}willBeInvokedByEvent(e){const t=e.target;return this.element===t||(t instanceof Element&&this.element.contains(t)?this.scope.containsElement(t):this.scope.containsElement(this.action.element))}get controller(){return this.context.controller}get methodName(){return this.action.methodName}get element(){return this.scope.element}get scope(){return this.context.scope}}class st{constructor(e,t){this.mutationObserverInit={attributes:!0,childList:!0,subtree:!0},this.element=e,this.started=!1,this.delegate=t,this.elements=new Set,this.mutationObserver=new MutationObserver((e=>this.processMutations(e)))}start(){this.started||(this.started=!0,this.mutationObserver.observe(this.element,this.mutationObserverInit),this.refresh())}pause(e){this.started&&(this.mutationObserver.disconnect(),this.started=!1),e(),this.started||(this.mutationObserver.observe(this.element,this.mutationObserverInit),this.started=!0)}stop(){this.started&&(this.mutationObserver.takeRecords(),this.mutationObserver.disconnect(),this.started=!1)}refresh(){if(this.started){const e=new Set(this.matchElementsInTree());for(const t of Array.from(this.elements))e.has(t)||this.removeElement(t);for(const t of Array.from(e))this.addElement(t)}}processMutations(e){if(this.started)for(const t of e)this.processMutation(t)}processMutation(e){"attributes"==e.type?this.processAttributeChange(e.target,e.attributeName):"childList"==e.type&&(this.processRemovedNodes(e.removedNodes),this.processAddedNodes(e.addedNodes))}processAttributeChange(e,t){const n=e;this.elements.has(n)?this.delegate.elementAttributeChanged&&this.matchElement(n)?this.delegate.elementAttributeChanged(n,t):this.removeElement(n):this.matchElement(n)&&this.addElement(n)}processRemovedNodes(e){for(const t of Array.from(e)){const e=this.elementFromNode(t);e&&this.processTree(e,this.removeElement)}}processAddedNodes(e){for(const t of Array.from(e)){const e=this.elementFromNode(t);e&&this.elementIsActive(e)&&this.processTree(e,this.addElement)}}matchElement(e){return this.delegate.matchElement(e)}matchElementsInTree(e=this.element){return this.delegate.matchElementsInTree(e)}processTree(e,t){for(const n of this.matchElementsInTree(e))t.call(this,n)}elementFromNode(e){if(e.nodeType==Node.ELEMENT_NODE)return e}elementIsActive(e){return e.isConnected==this.element.isConnected&&this.element.contains(e)}addElement(e){this.elements.has(e)||this.elementIsActive(e)&&(this.elements.add(e),this.delegate.elementMatched&&this.delegate.elementMatched(e))}removeElement(e){this.elements.has(e)&&(this.elements.delete(e),this.delegate.elementUnmatched&&this.delegate.elementUnmatched(e))}}class ot{constructor(e,t,n){this.attributeName=t,this.delegate=n,this.elementObserver=new st(e,this)}get element(){return this.elementObserver.element}get selector(){return`[${this.attributeName}]`}start(){this.elementObserver.start()}pause(e){this.elementObserver.pause(e)}stop(){this.elementObserver.stop()}refresh(){this.elementObserver.refresh()}get started(){return this.elementObserver.started}matchElement(e){return e.hasAttribute(this.attributeName)}matchElementsInTree(e){const t=this.matchElement(e)?[e]:[],n=Array.from(e.querySelectorAll(this.selector));return t.concat(n)}elementMatched(e){this.delegate.elementMatchedAttribute&&this.delegate.elementMatchedAttribute(e,this.attributeName)}elementUnmatched(e){this.delegate.elementUnmatchedAttribute&&this.delegate.elementUnmatchedAttribute(e,this.attributeName)}elementAttributeChanged(e,t){this.delegate.elementAttributeValueChanged&&this.attributeName==t&&this.delegate.elementAttributeValueChanged(e,t)}}class at{constructor(e,t){this.element=e,this.delegate=t,this.started=!1,this.stringMap=new Map,this.mutationObserver=new MutationObserver((e=>this.processMutations(e)))}start(){this.started||(this.started=!0,this.mutationObserver.observe(this.element,{attributes:!0,attributeOldValue:!0}),this.refresh())}stop(){this.started&&(this.mutationObserver.takeRecords(),this.mutationObserver.disconnect(),this.started=!1)}refresh(){if(this.started)for(const e of this.knownAttributeNames)this.refreshAttribute(e,null)}processMutations(e){if(this.started)for(const t of e)this.processMutation(t)}processMutation(e){const t=e.attributeName;t&&this.refreshAttribute(t,e.oldValue)}refreshAttribute(e,t){const n=this.delegate.getStringMapKeyForAttribute(e);if(null!=n){this.stringMap.has(e)||this.stringMapKeyAdded(n,e);const r=this.element.getAttribute(e);if(this.stringMap.get(e)!=r&&this.stringMapValueChanged(r,n,t),null==r){const t=this.stringMap.get(e);this.stringMap.delete(e),t&&this.stringMapKeyRemoved(n,e,t)}else this.stringMap.set(e,r)}}stringMapKeyAdded(e,t){this.delegate.stringMapKeyAdded&&this.delegate.stringMapKeyAdded(e,t)}stringMapValueChanged(e,t,n){this.delegate.stringMapValueChanged&&this.delegate.stringMapValueChanged(e,t,n)}stringMapKeyRemoved(e,t,n){this.delegate.stringMapKeyRemoved&&this.delegate.stringMapKeyRemoved(e,t,n)}get knownAttributeNames(){return Array.from(new Set(this.currentAttributeNames.concat(this.recordedAttributeNames)))}get currentAttributeNames(){return Array.from(this.element.attributes).map((e=>e.name))}get recordedAttributeNames(){return Array.from(this.stringMap.keys())}}function ct(e,t){let n=e.get(t);return n||(n=new Set,e.set(t,n)),n}class lt{constructor(){this.valuesByKey=new Map}get keys(){return Array.from(this.valuesByKey.keys())}get values(){return Array.from(this.valuesByKey.values()).reduce(((e,t)=>e.concat(Array.from(t))),[])}get size(){return Array.from(this.valuesByKey.values()).reduce(((e,t)=>e+t.size),0)}add(e,t){!function(e,t,n){ct(e,t).add(n)}(this.valuesByKey,e,t)}delete(e,t){!function(e,t,n){ct(e,t).delete(n),function(e,t){const n=e.get(t);null!=n&&0==n.size&&e.delete(t)}(e,t)}(this.valuesByKey,e,t)}has(e,t){const n=this.valuesByKey.get(e);return null!=n&&n.has(t)}hasKey(e){return this.valuesByKey.has(e)}hasValue(e){return Array.from(this.valuesByKey.values()).some((t=>t.has(e)))}getValuesForKey(e){const t=this.valuesByKey.get(e);return t?Array.from(t):[]}getKeysForValue(e){return Array.from(this.valuesByKey).filter((([t,n])=>n.has(e))).map((([e,t])=>e))}}class ut{constructor(e,t,n){this.attributeObserver=new ot(e,t,this),this.delegate=n,this.tokensByElement=new lt}get started(){return this.attributeObserver.started}start(){this.attributeObserver.start()}pause(e){this.attributeObserver.pause(e)}stop(){this.attributeObserver.stop()}refresh(){this.attributeObserver.refresh()}get element(){return this.attributeObserver.element}get attributeName(){return this.attributeObserver.attributeName}elementMatchedAttribute(e){this.tokensMatched(this.readTokensForElement(e))}elementAttributeValueChanged(e){const[t,n]=this.refreshTokensForElement(e);this.tokensUnmatched(t),this.tokensMatched(n)}elementUnmatchedAttribute(e){this.tokensUnmatched(this.tokensByElement.getValuesForKey(e))}tokensMatched(e){e.forEach((e=>this.tokenMatched(e)))}tokensUnmatched(e){e.forEach((e=>this.tokenUnmatched(e)))}tokenMatched(e){this.delegate.tokenMatched(e),this.tokensByElement.add(e.element,e)}tokenUnmatched(e){this.delegate.tokenUnmatched(e),this.tokensByElement.delete(e.element,e)}refreshTokensForElement(e){const t=this.tokensByElement.getValuesForKey(e),n=this.readTokensForElement(e),r=function(e,t){const n=Math.max(e.length,t.length);return Array.from({length:n},((n,r)=>[e[r],t[r]]))}(t,n).findIndex((([e,t])=>!function(e,t){return e&&t&&e.index==t.index&&e.content==t.content}(e,t)));return-1==r?[[],[]]:[t.slice(r),n.slice(r)]}readTokensForElement(e){const t=this.attributeName;return function(e,t,n){return e.trim().split(/\s+/).filter((e=>e.length)).map(((e,r)=>({element:t,attributeName:n,content:e,index:r})))}(e.getAttribute(t)||"",e,t)}}class ht{constructor(e,t,n){this.tokenListObserver=new ut(e,t,this),this.delegate=n,this.parseResultsByToken=new WeakMap,this.valuesByTokenByElement=new WeakMap}get started(){return this.tokenListObserver.started}start(){this.tokenListObserver.start()}stop(){this.tokenListObserver.stop()}refresh(){this.tokenListObserver.refresh()}get element(){return this.tokenListObserver.element}get attributeName(){return this.tokenListObserver.attributeName}tokenMatched(e){const{element:t}=e,{value:n}=this.fetchParseResultForToken(e);n&&(this.fetchValuesByTokenForElement(t).set(e,n),this.delegate.elementMatchedValue(t,n))}tokenUnmatched(e){const{element:t}=e,{value:n}=this.fetchParseResultForToken(e);n&&(this.fetchValuesByTokenForElement(t).delete(e),this.delegate.elementUnmatchedValue(t,n))}fetchParseResultForToken(e){let t=this.parseResultsByToken.get(e);return t||(t=this.parseToken(e),this.parseResultsByToken.set(e,t)),t}fetchValuesByTokenForElement(e){let t=this.valuesByTokenByElement.get(e);return t||(t=new Map,this.valuesByTokenByElement.set(e,t)),t}parseToken(e){try{return{value:this.delegate.parseValueForToken(e)}}catch(e){return{error:e}}}}class dt{constructor(e,t){this.context=e,this.delegate=t,this.bindingsByAction=new Map}start(){this.valueListObserver||(this.valueListObserver=new ht(this.element,this.actionAttribute,this),this.valueListObserver.start())}stop(){this.valueListObserver&&(this.valueListObserver.stop(),delete this.valueListObserver,this.disconnectAllActions())}get element(){return this.context.element}get identifier(){return this.context.identifier}get actionAttribute(){return this.schema.actionAttribute}get schema(){return this.context.schema}get bindings(){return Array.from(this.bindingsByAction.values())}connectAction(e){const t=new it(this.context,e);this.bindingsByAction.set(e,t),this.delegate.bindingConnected(t)}disconnectAction(e){const t=this.bindingsByAction.get(e);t&&(this.bindingsByAction.delete(e),this.delegate.bindingDisconnected(t))}disconnectAllActions(){this.bindings.forEach((e=>this.delegate.bindingDisconnected(e))),this.bindingsByAction.clear()}parseValueForToken(e){const t=class{constructor(e,t,n){this.element=e,this.index=t,this.eventTarget=n.eventTarget||e,this.eventName=n.eventName||function(e){const t=e.tagName.toLowerCase();if(t in tt)return tt[t](e)}(e)||nt("missing event name"),this.eventOptions=n.eventOptions||{},this.identifier=n.identifier||nt("missing identifier"),this.methodName=n.methodName||nt("missing method name")}static forToken(e){return new this(e.element,e.index,function(e){const t=e.trim().match(Xe)||[];return{eventTarget:Qe(t[4]),eventName:t[2],eventOptions:t[9]?(n=t[9],n.split(":").reduce(((e,t)=>Object.assign(e,{[t.replace(/^!/,"")]:!/^!/.test(t)})),{})):{},identifier:t[5],methodName:t[7]};var n}(e.content))}toString(){const e=this.eventTargetName?`@${this.eventTargetName}`:"";return`${this.eventName}${e}->${this.identifier}#${this.methodName}`}get params(){return this.eventTarget instanceof Element?this.getParamsFromEventTargetAttributes(this.eventTarget):{}}getParamsFromEventTargetAttributes(e){const t={},n=new RegExp(`^data-${this.identifier}-(.+)-param$`);return Array.from(e.attributes).forEach((({name:e,value:r})=>{const i=e.match(n),s=i&&i[1];s&&Object.assign(t,{[Ge(s)]:rt(r)})})),t}get eventTargetName(){return(e=this.eventTarget)==window?"window":e==document?"document":void 0;var e}}.forToken(e);if(t.identifier==this.identifier)return t}elementMatchedValue(e,t){this.connectAction(t)}elementUnmatchedValue(e,t){this.disconnectAction(t)}}class pt{constructor(e,t){this.context=e,this.receiver=t,this.stringMapObserver=new at(this.element,this),this.valueDescriptorMap=this.controller.valueDescriptorMap,this.invokeChangedCallbacksForDefaultValues()}start(){this.stringMapObserver.start()}stop(){this.stringMapObserver.stop()}get element(){return this.context.element}get controller(){return this.context.controller}getStringMapKeyForAttribute(e){if(e in this.valueDescriptorMap)return this.valueDescriptorMap[e].name}stringMapKeyAdded(e,t){const n=this.valueDescriptorMap[t];this.hasValue(e)||this.invokeChangedCallback(e,n.writer(this.receiver[e]),n.writer(n.defaultValue))}stringMapValueChanged(e,t,n){const r=this.valueDescriptorNameMap[t];null!==e&&(null===n&&(n=r.writer(r.defaultValue)),this.invokeChangedCallback(t,e,n))}stringMapKeyRemoved(e,t,n){const r=this.valueDescriptorNameMap[e];this.hasValue(e)?this.invokeChangedCallback(e,r.writer(this.receiver[e]),n):this.invokeChangedCallback(e,r.writer(r.defaultValue),n)}invokeChangedCallbacksForDefaultValues(){for(const{key:e,name:t,defaultValue:n,writer:r}of this.valueDescriptors)null==n||this.controller.data.has(e)||this.invokeChangedCallback(t,r(n),void 0)}invokeChangedCallback(e,t,n){const r=`${e}Changed`,i=this.receiver[r];if("function"==typeof i){const r=this.valueDescriptorNameMap[e],s=r.reader(t);let o=n;n&&(o=r.reader(n)),i.call(this.receiver,s,o)}}get valueDescriptors(){const{valueDescriptorMap:e}=this;return Object.keys(e).map((t=>e[t]))}get valueDescriptorNameMap(){const e={};return Object.keys(this.valueDescriptorMap).forEach((t=>{const n=this.valueDescriptorMap[t];e[n.name]=n})),e}hasValue(e){const t=`has${Ze(this.valueDescriptorNameMap[e].name)}`;return this.receiver[t]}}class ft{constructor(e,t){this.context=e,this.delegate=t,this.targetsByName=new lt}start(){this.tokenListObserver||(this.tokenListObserver=new ut(this.element,this.attributeName,this),this.tokenListObserver.start())}stop(){this.tokenListObserver&&(this.disconnectAllTargets(),this.tokenListObserver.stop(),delete this.tokenListObserver)}tokenMatched({element:e,content:t}){this.scope.containsElement(e)&&this.connectTarget(e,t)}tokenUnmatched({element:e,content:t}){this.disconnectTarget(e,t)}connectTarget(e,t){var n;this.targetsByName.has(t,e)||(this.targetsByName.add(t,e),null===(n=this.tokenListObserver)||void 0===n||n.pause((()=>this.delegate.targetConnected(e,t))))}disconnectTarget(e,t){var n;this.targetsByName.has(t,e)&&(this.targetsByName.delete(t,e),null===(n=this.tokenListObserver)||void 0===n||n.pause((()=>this.delegate.targetDisconnected(e,t))))}disconnectAllTargets(){for(const e of this.targetsByName.keys)for(const t of this.targetsByName.getValuesForKey(e))this.disconnectTarget(t,e)}get attributeName(){return`data-${this.context.identifier}-target`}get element(){return this.context.element}get scope(){return this.context.scope}}class gt{constructor(e,t){this.logDebugActivity=(e,t={})=>{const{identifier:n,controller:r,element:i}=this;t=Object.assign({identifier:n,controller:r,element:i},t),this.application.logDebugActivity(this.identifier,e,t)},this.module=e,this.scope=t,this.controller=new e.controllerConstructor(this),this.bindingObserver=new dt(this,this.dispatcher),this.valueObserver=new pt(this,this.controller),this.targetObserver=new ft(this,this);try{this.controller.initialize(),this.logDebugActivity("initialize")}catch(e){this.handleError(e,"initializing controller")}}connect(){this.bindingObserver.start(),this.valueObserver.start(),this.targetObserver.start();try{this.controller.connect(),this.logDebugActivity("connect")}catch(e){this.handleError(e,"connecting controller")}}disconnect(){try{this.controller.disconnect(),this.logDebugActivity("disconnect")}catch(e){this.handleError(e,"disconnecting controller")}this.targetObserver.stop(),this.valueObserver.stop(),this.bindingObserver.stop()}get application(){return this.module.application}get identifier(){return this.module.identifier}get schema(){return this.application.schema}get dispatcher(){return this.application.dispatcher}get element(){return this.scope.element}get parentElement(){return this.element.parentElement}handleError(e,t,n={}){const{identifier:r,controller:i,element:s}=this;n=Object.assign({identifier:r,controller:i,element:s},n),this.application.handleError(e,`Error ${t}`,n)}targetConnected(e,t){this.invokeControllerMethod(`${t}TargetConnected`,e)}targetDisconnected(e,t){this.invokeControllerMethod(`${t}TargetDisconnected`,e)}invokeControllerMethod(e,...t){const n=this.controller;"function"==typeof n[e]&&n[e](...t)}}function mt(e,t){const n=bt(e);return Array.from(n.reduce(((e,n)=>(function(e,t){const n=e[t];return Array.isArray(n)?n:[]}(n,t).forEach((t=>e.add(t))),e)),new Set))}function vt(e,t){return bt(e).reduce(((e,n)=>(e.push(...function(e,t){const n=e[t];return n?Object.keys(n).map((e=>[e,n[e]])):[]}(n,t)),e)),[])}function bt(e){const t=[];for(;e;)t.push(e),e=Object.getPrototypeOf(e);return t.reverse()}function yt(e){return function(e,t){const n=Tt(e),r=function(e,t){return wt(t).reduce(((n,r)=>{const i=function(e,t,n){const r=Object.getOwnPropertyDescriptor(e,n);if(!r||!("value"in r)){const e=Object.getOwnPropertyDescriptor(t,n).value;return r&&(e.get=r.get||e.get,e.set=r.set||e.set),e}}(e,t,r);return i&&Object.assign(n,{[r]:i}),n}),{})}(e.prototype,t);return Object.defineProperties(n.prototype,r),n}(e,function(e){return mt(e,"blessings").reduce(((t,n)=>{const r=n(e);for(const e in r){const n=t[e]||{};t[e]=Object.assign(n,r[e])}return t}),{})}(e))}const wt="function"==typeof Object.getOwnPropertySymbols?e=>[...Object.getOwnPropertyNames(e),...Object.getOwnPropertySymbols(e)]:Object.getOwnPropertyNames,Tt=(()=>{function e(e){function t(){return Reflect.construct(e,arguments,new.target)}return t.prototype=Object.create(e.prototype,{constructor:{value:t}}),Reflect.setPrototypeOf(t,e),t}try{return function(){const t=e((function(){this.a.call(this)}));t.prototype.a=function(){},new t}(),e}catch(e){return e=>class extends e{}}})();class Et{constructor(e,t){this.application=e,this.definition=function(e){return{identifier:e.identifier,controllerConstructor:yt(e.controllerConstructor)}}(t),this.contextsByScope=new WeakMap,this.connectedContexts=new Set}get identifier(){return this.definition.identifier}get controllerConstructor(){return this.definition.controllerConstructor}get contexts(){return Array.from(this.connectedContexts)}connectContextForScope(e){const t=this.fetchContextForScope(e);this.connectedContexts.add(t),t.connect()}disconnectContextForScope(e){const t=this.contextsByScope.get(e);t&&(this.connectedContexts.delete(t),t.disconnect())}fetchContextForScope(e){let t=this.contextsByScope.get(e);return t||(t=new gt(this,e),this.contextsByScope.set(e,t)),t}}class Ot{constructor(e){this.scope=e}has(e){return this.data.has(this.getDataKey(e))}get(e){return this.getAll(e)[0]}getAll(e){const t=this.data.get(this.getDataKey(e))||"";return t.match(/[^\s]+/g)||[]}getAttributeName(e){return this.data.getAttributeNameForKey(this.getDataKey(e))}getDataKey(e){return`${e}-class`}get data(){return this.scope.data}}class At{constructor(e){this.scope=e}get element(){return this.scope.element}get identifier(){return this.scope.identifier}get(e){const t=this.getAttributeNameForKey(e);return this.element.getAttribute(t)}set(e,t){const n=this.getAttributeNameForKey(e);return this.element.setAttribute(n,t),this.get(e)}has(e){const t=this.getAttributeNameForKey(e);return this.element.hasAttribute(t)}delete(e){if(this.has(e)){const t=this.getAttributeNameForKey(e);return this.element.removeAttribute(t),!0}return!1}getAttributeNameForKey(e){return`data-${this.identifier}-${et(e)}`}}class xt{constructor(e){this.warnedKeysByObject=new WeakMap,this.logger=e}warn(e,t,n){let r=this.warnedKeysByObject.get(e);r||(r=new Set,this.warnedKeysByObject.set(e,r)),r.has(t)||(r.add(t),this.logger.warn(n,e))}}function kt(e,t){return`[${e}~="${t}"]`}class Ct{constructor(e){this.scope=e}get element(){return this.scope.element}get identifier(){return this.scope.identifier}get schema(){return this.scope.schema}has(e){return null!=this.find(e)}find(...e){return e.reduce(((e,t)=>e||this.findTarget(t)||this.findLegacyTarget(t)),void 0)}findAll(...e){return e.reduce(((e,t)=>[...e,...this.findAllTargets(t),...this.findAllLegacyTargets(t)]),[])}findTarget(e){const t=this.getSelectorForTargetName(e);return this.scope.findElement(t)}findAllTargets(e){const t=this.getSelectorForTargetName(e);return this.scope.findAllElements(t)}getSelectorForTargetName(e){return kt(this.schema.targetAttributeForScope(this.identifier),e)}findLegacyTarget(e){const t=this.getLegacySelectorForTargetName(e);return this.deprecate(this.scope.findElement(t),e)}findAllLegacyTargets(e){const t=this.getLegacySelectorForTargetName(e);return this.scope.findAllElements(t).map((t=>this.deprecate(t,e)))}getLegacySelectorForTargetName(e){const t=`${this.identifier}.${e}`;return kt(this.schema.targetAttribute,t)}deprecate(e,t){if(e){const{identifier:n}=this,r=this.schema.targetAttribute,i=this.schema.targetAttributeForScope(n);this.guide.warn(e,`target:${t}`,`Please replace ${r}="${n}.${t}" with ${i}="${t}". The ${r} attribute is deprecated and will be removed in a future version of Stimulus.`)}return e}get guide(){return this.scope.guide}}class Lt{constructor(e,t,n,r){this.targets=new Ct(this),this.classes=new Ot(this),this.data=new At(this),this.containsElement=e=>e.closest(this.controllerSelector)===this.element,this.schema=e,this.element=t,this.identifier=n,this.guide=new xt(r)}findElement(e){return this.element.matches(e)?this.element:this.queryElements(e).find(this.containsElement)}findAllElements(e){return[...this.element.matches(e)?[this.element]:[],...this.queryElements(e).filter(this.containsElement)]}queryElements(e){return Array.from(this.element.querySelectorAll(e))}get controllerSelector(){return kt(this.schema.controllerAttribute,this.identifier)}}class Mt{constructor(e,t,n){this.element=e,this.schema=t,this.delegate=n,this.valueListObserver=new ht(this.element,this.controllerAttribute,this),this.scopesByIdentifierByElement=new WeakMap,this.scopeReferenceCounts=new WeakMap}start(){this.valueListObserver.start()}stop(){this.valueListObserver.stop()}get controllerAttribute(){return this.schema.controllerAttribute}parseValueForToken(e){const{element:t,content:n}=e,r=this.fetchScopesByIdentifierForElement(t);let i=r.get(n);return i||(i=this.delegate.createScopeForElementAndIdentifier(t,n),r.set(n,i)),i}elementMatchedValue(e,t){const n=(this.scopeReferenceCounts.get(t)||0)+1;this.scopeReferenceCounts.set(t,n),1==n&&this.delegate.scopeConnected(t)}elementUnmatchedValue(e,t){const n=this.scopeReferenceCounts.get(t);n&&(this.scopeReferenceCounts.set(t,n-1),1==n&&this.delegate.scopeDisconnected(t))}fetchScopesByIdentifierForElement(e){let t=this.scopesByIdentifierByElement.get(e);return t||(t=new Map,this.scopesByIdentifierByElement.set(e,t)),t}}class Dt{constructor(e){this.application=e,this.scopeObserver=new Mt(this.element,this.schema,this),this.scopesByIdentifier=new lt,this.modulesByIdentifier=new Map}get element(){return this.application.element}get schema(){return this.application.schema}get logger(){return this.application.logger}get controllerAttribute(){return this.schema.controllerAttribute}get modules(){return Array.from(this.modulesByIdentifier.values())}get contexts(){return this.modules.reduce(((e,t)=>e.concat(t.contexts)),[])}start(){this.scopeObserver.start()}stop(){this.scopeObserver.stop()}loadDefinition(e){this.unloadIdentifier(e.identifier);const t=new Et(this.application,e);this.connectModule(t)}unloadIdentifier(e){const t=this.modulesByIdentifier.get(e);t&&this.disconnectModule(t)}getContextForElementAndIdentifier(e,t){const n=this.modulesByIdentifier.get(t);if(n)return n.contexts.find((t=>t.element==e))}handleError(e,t,n){this.application.handleError(e,t,n)}createScopeForElementAndIdentifier(e,t){return new Lt(this.schema,e,t,this.logger)}scopeConnected(e){this.scopesByIdentifier.add(e.identifier,e);const t=this.modulesByIdentifier.get(e.identifier);t&&t.connectContextForScope(e)}scopeDisconnected(e){this.scopesByIdentifier.delete(e.identifier,e);const t=this.modulesByIdentifier.get(e.identifier);t&&t.disconnectContextForScope(e)}connectModule(e){this.modulesByIdentifier.set(e.identifier,e);this.scopesByIdentifier.getValuesForKey(e.identifier).forEach((t=>e.connectContextForScope(t)))}disconnectModule(e){this.modulesByIdentifier.delete(e.identifier);this.scopesByIdentifier.getValuesForKey(e.identifier).forEach((t=>e.disconnectContextForScope(t)))}}const Bt={controllerAttribute:"data-controller",actionAttribute:"data-action",targetAttribute:"data-target",targetAttributeForScope:e=>`data-${e}-target`};class Nt{constructor(e=document.documentElement,t=Bt){this.logger=console,this.debug=!1,this.logDebugActivity=(e,t,n={})=>{this.debug&&this.logFormattedMessage(e,t,n)},this.element=e,this.schema=t,this.dispatcher=new Je(this),this.router=new Dt(this)}static start(e,t){const n=new Nt(e,t);return n.start(),n}async start(){await new Promise((e=>{"loading"==document.readyState?document.addEventListener("DOMContentLoaded",(()=>e())):e()})),this.logDebugActivity("application","starting"),this.dispatcher.start(),this.router.start(),this.logDebugActivity("application","start")}stop(){this.logDebugActivity("application","stopping"),this.dispatcher.stop(),this.router.stop(),this.logDebugActivity("application","stop")}register(e,t){t.shouldLoad&&this.load({identifier:e,controllerConstructor:t})}load(e,...t){(Array.isArray(e)?e:[e,...t]).forEach((e=>this.router.loadDefinition(e)))}unload(e,...t){(Array.isArray(e)?e:[e,...t]).forEach((e=>this.router.unloadIdentifier(e)))}get controllers(){return this.router.contexts.map((e=>e.controller))}getControllerForElementAndIdentifier(e,t){const n=this.router.getContextForElementAndIdentifier(e,t);return n?n.controller:null}handleError(e,t,n){var r;this.logger.error("%s\n\n%o\n\n%o",t,e,n),null===(r=window.onerror)||void 0===r||r.call(window,t,"",0,0,e)}logFormattedMessage(e,t,n={}){n=Object.assign({application:this},n),this.logger.groupCollapsed(`${e} #${t}`),this.logger.log("details:",Object.assign({},n)),this.logger.groupEnd()}}function St([e,t]){return function(e,t){const n=`${et(e)}-value`,r=function(e){const t=function(e){const t=jt(e.type);if(t){const n=It(e.default);if(t!==n)throw new Error(`Type "${t}" must match the type of the default value. Given default value: "${e.default}" as "${n}"`);return t}}(e),n=It(e),r=jt(e),i=t||n||r;if(i)return i;throw new Error(`Unknown value type "${e}"`)}(t);return{type:r,key:n,name:Ge(n),get defaultValue(){return function(e){const t=jt(e);if(t)return Vt[t];const n=e.default;return void 0!==n?n:e}(t)},get hasCustomDefaultValue(){return void 0!==It(t)},reader:Ft[r],writer:$t[r]||$t.default}}(e,t)}function jt(e){switch(e){case Array:return"array";case Boolean:return"boolean";case Number:return"number";case Object:return"object";case String:return"string"}}function It(e){switch(typeof e){case"boolean":return"boolean";case"number":return"number";case"string":return"string"}return Array.isArray(e)?"array":"[object Object]"===Object.prototype.toString.call(e)?"object":void 0}const Vt={get array(){return[]},boolean:!1,number:0,get object(){return{}},string:""},Ft={array(e){const t=JSON.parse(e);if(!Array.isArray(t))throw new TypeError("Expected array");return t},boolean:e=>!("0"==e||"false"==e),number:e=>Number(e),object(e){const t=JSON.parse(e);if(null===t||"object"!=typeof t||Array.isArray(t))throw new TypeError("Expected object");return t},string:e=>e},$t={default:function(e){return`${e}`},array:_t,object:_t};function _t(e){return JSON.stringify(e)}class Pt{constructor(e){this.context=e}static get shouldLoad(){return!0}get application(){return this.context.application}get scope(){return this.context.scope}get element(){return this.scope.element}get identifier(){return this.scope.identifier}get targets(){return this.scope.targets}get classes(){return this.scope.classes}get data(){return this.scope.data}initialize(){}connect(){}disconnect(){}dispatch(e,{target:t=this.element,detail:n={},prefix:r=this.identifier,bubbles:i=!0,cancelable:s=!0}={}){const o=new CustomEvent(r?`${r}:${e}`:e,{detail:n,bubbles:i,cancelable:s});return t.dispatchEvent(o),o}}Pt.blessings=[function(e){return mt(e,"classes").reduce(((e,t)=>{return Object.assign(e,{[`${n=t}Class`]:{get(){const{classes:e}=this;if(e.has(n))return e.get(n);{const t=e.getAttributeName(n);throw new Error(`Missing attribute "${t}"`)}}},[`${n}Classes`]:{get(){return this.classes.getAll(n)}},[`has${Ze(n)}Class`]:{get(){return this.classes.has(n)}}});var n}),{})},function(e){return mt(e,"targets").reduce(((e,t)=>{return Object.assign(e,{[`${n=t}Target`]:{get(){const e=this.targets.find(n);if(e)return e;throw new Error(`Missing target element "${n}" for "${this.identifier}" controller`)}},[`${n}Targets`]:{get(){return this.targets.findAll(n)}},[`has${Ze(n)}Target`]:{get(){return this.targets.has(n)}}});var n}),{})},function(e){const t=vt(e,"values"),n={valueDescriptorMap:{get(){return t.reduce(((e,t)=>{const n=St(t),r=this.data.getAttributeNameForKey(n.key);return Object.assign(e,{[r]:n})}),{})}}};return t.reduce(((e,t)=>Object.assign(e,function(e){const t=St(e),{key:n,name:r,reader:i,writer:s}=t;return{[r]:{get(){const e=this.data.get(n);return null!==e?i(e):t.defaultValue},set(e){void 0===e?this.data.delete(n):this.data.set(n,s(e))}},[`has${Ze(r)}`]:{get(){return this.data.has(n)||t.hasCustomDefaultValue}}}}(t))),n)}],Pt.targets=[],Pt.values={};(class extends Pt{initialize(){this.hide()}connect(){setTimeout((()=>{this.show()}),200),this.hasDismissAfterValue&&setTimeout((()=>{this.close()}),this.dismissAfterValue)}close(){this.hide(),setTimeout((()=>{this.element.remove()}),1100)}show(){this.element.setAttribute("style","transition: 1s; transform:translate(0, 0);")}hide(){this.element.setAttribute("style","transition: 1s; transform:translate(400px, 0);")}}).values={dismissAfter:Number};(class extends Pt{connect(){this.timeout=null,this.duration=this.data.get("duration")||1e3}save(){clearTimeout(this.timeout),this.timeout=setTimeout((()=>{this.statusTarget.textContent="Saving...",Rails.fire(this.formTarget,"submit")}),this.duration)}success(){this.setStatus("Saved!")}error(){this.setStatus("Unable to save!")}setStatus(e){this.statusTarget.textContent=e,this.timeout=setTimeout((()=>{this.statusTarget.textContent=""}),2e3)}}).targets=["form","status"];class Rt extends Pt{constructor(...e){super(...e),this._onMenuButtonKeydown=e=>{switch(e.keyCode){case 13:case 32:e.preventDefault(),this.toggle()}}}connect(){this.toggleClass=this.data.get("class")||"hidden",this.visibleClass=this.data.get("visibleClass")||null,this.invisibleClass=this.data.get("invisibleClass")||null,this.activeClass=this.data.get("activeClass")||null,this.enteringClass=this.data.get("enteringClass")||null,this.leavingClass=this.data.get("leavingClass")||null,this.hasButtonTarget&&this.buttonTarget.addEventListener("keydown",this._onMenuButtonKeydown),this.element.setAttribute("aria-haspopup","true")}disconnect(){this.hasButtonTarget&&this.buttonTarget.removeEventListener("keydown",this._onMenuButtonKeydown)}toggle(){this.openValue=!this.openValue}openValueChanged(){this.openValue?this._show():this._hide()}_show(e){setTimeout((()=>{this.menuTarget.classList.remove(this.toggleClass),this.element.setAttribute("aria-expanded","true"),this._enteringClassList[0].forEach((e=>{this.menuTarget.classList.add(e)}).bind(this)),this._activeClassList[0].forEach((e=>{this.activeTarget.classList.add(e)})),this._invisibleClassList[0].forEach((e=>this.menuTarget.classList.remove(e))),this._visibleClassList[0].forEach((e=>{this.menuTarget.classList.add(e)})),setTimeout((()=>{this._enteringClassList[0].forEach((e=>this.menuTarget.classList.remove(e)))}).bind(this),this.enterTimeout[0]),"function"==typeof e&&e()}).bind(this))}_hide(e){setTimeout((()=>{this.element.setAttribute("aria-expanded","false"),this._invisibleClassList[0].forEach((e=>this.menuTarget.classList.add(e))),this._visibleClassList[0].forEach((e=>this.menuTarget.classList.remove(e))),this._activeClassList[0].forEach((e=>this.activeTarget.classList.remove(e))),this._leavingClassList[0].forEach((e=>this.menuTarget.classList.add(e))),setTimeout((()=>{this._leavingClassList[0].forEach((e=>this.menuTarget.classList.remove(e))),"function"==typeof e&&e(),this.menuTarget.classList.add(this.toggleClass)}).bind(this),this.leaveTimeout[0])}).bind(this))}show(){this.openValue=!0}hide(e){!1===this.element.contains(e.target)&&this.openValue&&(this.openValue=!1)}get activeTarget(){return this.data.has("activeTarget")?document.querySelector(this.data.get("activeTarget")):this.element}get _activeClassList(){return this.activeClass?this.activeClass.split(",").map((e=>e.split(" "))):[[],[]]}get _visibleClassList(){return this.visibleClass?this.visibleClass.split(",").map((e=>e.split(" "))):[[],[]]}get _invisibleClassList(){return this.invisibleClass?this.invisibleClass.split(",").map((e=>e.split(" "))):[[],[]]}get _enteringClassList(){return this.enteringClass?this.enteringClass.split(",").map((e=>e.split(" "))):[[],[]]}get _leavingClassList(){return this.leavingClass?this.leavingClass.split(",").map((e=>e.split(" "))):[[],[]]}get enterTimeout(){return(this.data.get("enterTimeout")||"0,0").split(",").map((e=>parseInt(e)))}get leaveTimeout(){return(this.data.get("leaveTimeout")||"0,0").split(",").map((e=>parseInt(e)))}}Rt.targets=["menu","button"],Rt.values={open:Boolean};(class extends Pt{connect(){this.toggleClass=this.data.get("class")||"hidden",this.backgroundId=this.data.get("backgroundId")||"modal-background",this.backgroundHtml=this.data.get("backgroundHtml")||this._backgroundHTML(),this.allowBackgroundClose="true"===(this.data.get("allowBackgroundClose")||"true"),this.preventDefaultActionOpening="true"===(this.data.get("preventDefaultActionOpening")||"true"),this.preventDefaultActionClosing="true"===(this.data.get("preventDefaultActionClosing")||"true")}disconnect(){this.close()}open(e){this.preventDefaultActionOpening&&e.preventDefault(),e.target.blur&&e.target.blur(),this.lockScroll(),this.containerTarget.classList.remove(this.toggleClass),this.data.get("disable-backdrop")||(document.body.insertAdjacentHTML("beforeend",this.backgroundHtml),this.background=document.querySelector(`#${this.backgroundId}`))}close(e){e&&this.preventDefaultActionClosing&&e.preventDefault(),this.unlockScroll(),this.containerTarget.classList.add(this.toggleClass),this.background&&this.background.remove()}closeBackground(e){this.allowBackgroundClose&&e.target===this.containerTarget&&this.close(e)}closeWithKeyboard(e){27!==e.keyCode||this.containerTarget.classList.contains(this.toggleClass)||this.close(e)}_backgroundHTML(){return`<div id="${this.backgroundId}" class="fixed top-0 left-0 w-full h-full" style="background-color: rgba(0, 0, 0, 0.8); z-index: 9998;"></div>`}lockScroll(){const e=window.innerWidth-document.documentElement.clientWidth;document.body.style.paddingRight=`${e}px`,this.saveScrollPosition(),document.body.classList.add("fixed","inset-x-0","overflow-hidden"),document.body.style.top=`-${this.scrollPosition}px`}unlockScroll(){document.body.style.paddingRight=null,document.body.classList.remove("fixed","inset-x-0","overflow-hidden"),this.restoreScrollPosition(),document.body.style.top=null}saveScrollPosition(){this.scrollPosition=window.pageYOffset||document.body.scrollTop}restoreScrollPosition(){document.documentElement.scrollTop=this.scrollPosition}}).targets=["container"];(class extends Pt{connect(){this.activeTabClasses=(this.data.get("activeTab")||"active").split(" "),this.inactiveTabClasses=(this.data.get("inactiveTab")||"inactive").split(" "),this.anchor&&(this.index=this.tabTargets.findIndex((e=>e.id===this.anchor))),this.showTab()}change(e){e.preventDefault(),this.index=e.currentTarget.dataset.index?e.currentTarget.dataset.index:e.currentTarget.dataset.id?this.tabTargets.findIndex((t=>t.id==e.currentTarget.dataset.id)):this.tabTargets.indexOf(e.currentTarget),window.dispatchEvent(new CustomEvent("tsc:tab-change"))}showTab(){this.tabTargets.forEach(((e,t)=>{const n=this.panelTargets[t];t===this.index?(n.classList.remove("hidden"),e.classList.remove(...this.inactiveTabClasses),e.classList.add(...this.activeTabClasses),e.id&&(location.hash=e.id)):(n.classList.add("hidden"),e.classList.remove(...this.activeTabClasses),e.classList.add(...this.inactiveTabClasses))}))}get index(){return parseInt(this.data.get("index")||0)}set index(e){this.data.set("index",e>=0?e:0),this.showTab()}get anchor(){return document.URL.split("#").length>1?document.URL.split("#")[1]:null}}).targets=["tab","panel"];class Kt extends Pt{connect(){this.toggleClass=this.data.get("class")||"hidden"}toggle(e){e.preventDefault(),this.openValue=!this.openValue}hide(e){e.preventDefault(),this.openValue=!1}show(e){e.preventDefault(),this.openValue=!0}openValueChanged(){this.toggleClass&&this.toggleableTargets.forEach((e=>{e.classList.toggle(this.toggleClass)}))}}Kt.targets=["toggleable"],Kt.values={open:Boolean};(class extends Pt{initialize(){this.contentTarget.setAttribute("style",`transform:translate(${this.data.get("translateX")}, ${this.data.get("translateY")});`)}mouseOver(){this.contentTarget.classList.remove("hidden")}mouseOut(){this.contentTarget.classList.add("hidden")}}).targets=["content"];(class extends Rt{_show(){this.overlayTarget.classList.remove(this.toggleClass),super._show((()=>{this._activeClassList[1].forEach((e=>this.overlayTarget.classList.add(e))),this._invisibleClassList[1].forEach((e=>this.overlayTarget.classList.remove(e))),this._visibleClassList[1].forEach((e=>this.overlayTarget.classList.add(e))),setTimeout((()=>{this._enteringClassList[1].forEach((e=>this.overlayTarget.classList.remove(e)))}).bind(this),this.enterTimeout[1])}).bind(this))}_hide(){this._leavingClassList[1].forEach((e=>this.overlayTarget.classList.add(e))),super._hide((()=>{setTimeout((()=>{this._visibleClassList[1].forEach((e=>this.overlayTarget.classList.remove(e))),this._invisibleClassList[1].forEach((e=>this.overlayTarget.classList.add(e))),this._activeClassList[1].forEach((e=>this.overlayTarget.classList.remove(e))),this._leavingClassList[1].forEach((e=>this.overlayTarget.classList.remove(e))),this.overlayTarget.classList.add(this.toggleClass)}).bind(this),this.leaveTimeout[1])}).bind(this))}}).targets=["menu","overlay"];function Ut(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Wt(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Ht(e,t,n){return t&&Wt(e.prototype,t),n&&Wt(e,n),e}function qt(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function zt(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&Jt(e,t)}function Yt(e){return(Yt=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function Jt(e,t){return(Jt=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function Xt(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}function Qt(e,t,n){return(Qt=Xt()?Reflect.construct:function(e,t,n){var r=[null];r.push.apply(r,t);var i=new(Function.bind.apply(e,r));return n&&Jt(i,n.prototype),i}).apply(null,arguments)}function Gt(e,t){return!t||"object"!=typeof t&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function Zt(e){var t=Xt();return function(){var n,r=Yt(e);if(t){var i=Yt(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return Gt(this,n)}}function en(e){return function(e){if(Array.isArray(e))return tn(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(!e)return;if("string"==typeof e)return tn(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return tn(e,t)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function tn(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}(class extends Pt{connect(){this.styleProperty=this.data.get("style")||"backgroundColor"}update(){this.preview=this.color}set preview(e){this.previewTarget.style[this.styleProperty]=e;const t=this._getContrastYIQ(e);"color"===this.styleProperty?this.previewTarget.style.backgroundColor=t:this.previewTarget.style.color=t}get color(){return this.colorTarget.value}_getContrastYIQ(e){return e=e.replace("#",""),(299*parseInt(e.substr(0,2),16)+587*parseInt(e.substr(2,2),16)+114*parseInt(e.substr(4,2),16))/1e3>=128?"#000":"#fff"}}).targets=["preview","color"];var nn=function(e){zt(n,e);var t=Zt(n);function n(){return Ut(this,n),t.apply(this,arguments)}return Ht(n,[{key:"connect",value:function(){this.setCount()}},{key:"checkAll",value:function(){this.setAllCheckboxes(!0),this.setCount()}},{key:"checkNone",value:function(){this.setAllCheckboxes(!1),this.setCount()}},{key:"onChecked",value:function(){this.setCount()}},{key:"setAllCheckboxes",value:function(e){this.checkboxes.forEach((function(t){var n=t;n.disabled||(n.checked=e)}))}},{key:"setCount",value:function(){if(this.hasCountTarget){var e=this.selectedCheckboxes.length;this.countTarget.innerHTML="".concat(e," selected")}}},{key:"selectedCheckboxes",get:function(){return this.checkboxes.filter((function(e){return e.checked}))}},{key:"checkboxes",get:function(){return Qt(Array,en(this.element.querySelectorAll("input[type=checkbox]")))}}]),n}(Pt);qt(nn,"targets",["count"]);var rn=function(e){zt(n,e);var t=Zt(n);function n(){return Ut(this,n),t.apply(this,arguments)}return Ht(n,[{key:"selectAll",value:function(e){var t=e.target.checked;this.allTarget.indeterminate=!1,this._setAllCheckboxes(t),this._dispatch("change",{count:this.selectedCount})}},{key:"onSelected",value:function(){this.allTarget.indeterminate=!!this._indeterminate,this._dispatch("change",{count:this.selectedCount})}},{key:"selectedCount",get:function(){return this.selected.length}},{key:"selected",get:function(){return this.selectables.filter((function(e){return e.checked}))}},{key:"selectables",get:function(){return Qt(Array,en(this.selectableTargets))}},{key:"_setAllCheckboxes",value:function(e){this.selectables.forEach((function(t){var n=t;n.disabled||(n.checked=e)}))}},{key:"_indeterminate",get:function(){return this.selected.length!==this.selectableTargets.length&&this.selected.length>0}},{key:"_dispatch",value:function(e,t){window.dispatchEvent(new CustomEvent("rmp:select:".concat(e),{bubbles:!0,detail:t}))}}]),n}(Pt);qt(rn,"targets",["all","selectable"]);var sn=function(e){zt(n,e);var t=Zt(n);function n(){return Ut(this,n),t.apply(this,arguments)}return Ht(n,[{key:"apply",value:function(){location.href="".concat(window.location.pathname,"?").concat(this.params)}},{key:"post",value:function(){var e=document.head.querySelector('meta[name="csrf-token"]').content,t="".concat(window.location.pathname,"/destroy_all?").concat(this.params);fetch(t,{method:"DELETE",redirect:"follow",headers:{"Content-Type":"application/json",credentials:"same-origin"},body:JSON.stringify({authenticity_token:e})}).then((function(e){e.redirected&&(window.location.href=e.url)}))}},{key:"params",get:function(){return this.activeFilterTargets().map((function(e){return"".concat(e.name,"=").concat(e.value)})).join("&")}},{key:"activeFilterTargets",value:function(){return this.filterTargets.filter((function(e){return"checkbox"===e.type||"radio"===e.type?e.checked:e.value.length>0}))}}]),n}(Pt);qt(sn,"targets",["filter"]);var on=function(e){zt(n,e);var t=Zt(n);function n(){return Ut(this,n),t.apply(this,arguments)}return Ht(n,[{key:"clear",value:function(){this.eventTarget.value=null,window.dispatchEvent(new CustomEvent("search-controller:submit",{}))}},{key:"submit",value:function(e){e.preventDefault(),"Enter"!==e.key&&"click"!==e.type||window.dispatchEvent(new CustomEvent("search-controller:submit",{}))}}]),n}(Pt);qt(on,"targets",["field"]);var an=function(e){zt(n,e);var t=Zt(n);function n(){return Ut(this,n),t.apply(this,arguments)}return Ht(n,[{key:"enable",value:function(){this.enableTarget.disabled=!1}},{key:"disable",value:function(){this.enableTarget.disabled=!0}},{key:"change",value:function(e){e.type.match(/rmp:select:.*/)&&(e.detail.count>0?this.enable():this.disable())}}]),n}(Pt);qt(an,"targets",["enable"]);var cn=function(e){zt(n,e);var t=Zt(n);function n(){return Ut(this,n),t.apply(this,arguments)}return Ht(n,[{key:"connect",value:function(){this.hasButtonTarget&&(this.originalText=this.buttonTarget.innerText,this.successDuration=2e3)}},{key:"copy",value:function(e){e.preventDefault();var t=this.sourceTarget.innerText,n=this.data.get("filter");n&&(t=new RegExp(n).exec(t)[0]);var r=document.createElement("textarea");r.value=t,document.body.appendChild(r),r.select(),document.execCommand("copy"),document.body.removeChild(r),this.copied()}},{key:"copied",value:function(){var e=this;if(this.hasButtonTarget){this.timeout&&clearTimeout(this.timeout);var t=this.data.get("copiedClass");console.log(t),this.buttonTarget.classList.add(t),this.timeout=setTimeout((function(){e.buttonTarget.classList.remove(t)}),this.successDuration)}}}]),n}(Pt);qt(cn,"targets",["button","source"]);var ln=Nt.start();ln.register("dropdown",Rt),ln.register("checklist",nn),ln.register("selectable",rn),ln.register("filters",sn),ln.register("search",on),ln.register("enable",an),ln.register("clipboard",cn),document.addEventListener("DOMContentLoaded",(function(){var e;!function(){var e=document.getElementById("profiled-requests-table");if(e)for(var t=e.rows,n=function(t){var n=e.rows[t],r=n.dataset.link;r&&(n.onclick=function(){window.location.href=r})},r=1;r<t.length;r++)n(r)}(),document.querySelectorAll(".trace-bar").forEach((function(e){ze(e,{trigger:"click",content:e.children[0],theme:"rmp",maxWidth:"700px",placement:"bottom",interactive:!0,onShow:function(e){e.popper.querySelector(".popover-close").addEventListener("click",(function(){e.hide()}))},onHide:function(e){e.popper.querySelector(".popover-close").removeEventListener("click",(function(){e.hide()}))}})})),(e=document.getElementById("trace-search"))&&e.addEventListener("keyup",(function(e){"Enter"===e.key&&(e.preventDefault(),document.getElementById("trace-form").submit())}))}),!1)}));
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rails_mini_profiler
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.0
4
+ version: 0.6.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - hschne
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2021-09-12 00:00:00.000000000 Z
11
+ date: 2021-10-15 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: inline_svg
@@ -87,6 +87,7 @@ files:
87
87
  - app/javascript/images/chart.svg
88
88
  - app/javascript/images/check.svg
89
89
  - app/javascript/images/chevron.svg
90
+ - app/javascript/images/copy.svg
90
91
  - app/javascript/images/delete.svg
91
92
  - app/javascript/images/filter.svg
92
93
  - app/javascript/images/graph.svg
@@ -96,6 +97,7 @@ files:
96
97
  - app/javascript/images/setting.svg
97
98
  - app/javascript/images/show.svg
98
99
  - app/javascript/js/checklist_controller.js
100
+ - app/javascript/js/clipboard_controller.js
99
101
  - app/javascript/js/enable_controller.js
100
102
  - app/javascript/js/filter_controller.js
101
103
  - app/javascript/js/search_controller.js
@@ -207,6 +209,7 @@ files:
207
209
  - vendor/assets/images/chart.svg
208
210
  - vendor/assets/images/check.svg
209
211
  - vendor/assets/images/chevron.svg
212
+ - vendor/assets/images/copy.svg
210
213
  - vendor/assets/images/delete.svg
211
214
  - vendor/assets/images/filter.svg
212
215
  - vendor/assets/images/graph.svg