completion-kit 0.5.22 → 0.5.24
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/app/assets/stylesheets/completion_kit/application.css +19 -0
- data/app/models/completion_kit/dashboard_dismissal.rb +5 -1
- data/app/models/completion_kit/provider_credential.rb +1 -0
- data/app/models/completion_kit/run.rb +1 -1
- data/lib/completion_kit/engine.rb +15 -0
- data/lib/completion_kit/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 40c107320c801c5cfcb008355620aadb4bf8ec4776113f52dd5e2d5c130a2ce8
|
|
4
|
+
data.tar.gz: 840088253b8efcd92163e858f4d95783889007c6b9c32662db3a1004225462a9
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: b5efc624e8fe825ac927ec9bb87ffbc750e7862ec8aeb064a830d3f4b585136119db33a3f3d41a6064fb60db05fd93675bff9cb5b71007e9aea7722d79e6bdd6
|
|
7
|
+
data.tar.gz: d664c0f3e623ba91750f2752b60b4f2bc147a08f8287558f3cff466a7da5d60242d8275db63e15c10ea818fe5fe6f2dc4066ff85a138383c2e10e6cdd2b79ace
|
|
@@ -4802,6 +4802,25 @@ a.tag-mark {
|
|
|
4802
4802
|
border: 1px solid var(--ck-line-strong);
|
|
4803
4803
|
border-radius: var(--ck-radius);
|
|
4804
4804
|
box-shadow: 0 -16px 34px rgba(0, 0, 0, 0.5);
|
|
4805
|
+
scrollbar-width: thin;
|
|
4806
|
+
scrollbar-color: var(--ck-line-strong) transparent;
|
|
4807
|
+
}
|
|
4808
|
+
.ck-flyout__panel::-webkit-scrollbar {
|
|
4809
|
+
width: 10px;
|
|
4810
|
+
}
|
|
4811
|
+
.ck-flyout__panel::-webkit-scrollbar-track {
|
|
4812
|
+
background: transparent;
|
|
4813
|
+
}
|
|
4814
|
+
.ck-flyout__panel::-webkit-scrollbar-thumb {
|
|
4815
|
+
background: var(--ck-line-strong);
|
|
4816
|
+
border: 3px solid transparent;
|
|
4817
|
+
background-clip: padding-box;
|
|
4818
|
+
border-radius: 999px;
|
|
4819
|
+
}
|
|
4820
|
+
.ck-flyout__panel::-webkit-scrollbar-thumb:hover {
|
|
4821
|
+
background: var(--ck-dim);
|
|
4822
|
+
border: 3px solid transparent;
|
|
4823
|
+
background-clip: padding-box;
|
|
4805
4824
|
}
|
|
4806
4825
|
.ck-flyout__item {
|
|
4807
4826
|
display: flex;
|
|
@@ -12,7 +12,11 @@ module CompletionKit
|
|
|
12
12
|
validates :dismissable_type, inclusion: { in: DISMISSABLE_TYPES }
|
|
13
13
|
validates :dismissable_id, uniqueness: { scope: :dismissable_type }
|
|
14
14
|
|
|
15
|
-
scope :metrics,
|
|
15
|
+
scope :metrics, lambda {
|
|
16
|
+
where(dismissable_type: "CompletionKit::Metric")
|
|
17
|
+
.includes(:dismissable)
|
|
18
|
+
.order(Arel.sql("baseline_score DESC NULLS LAST"))
|
|
19
|
+
}
|
|
16
20
|
scope :failures, -> { where(dismissable_type: FAILURE_TYPES).includes(:dismissable) }
|
|
17
21
|
end
|
|
18
22
|
end
|
|
@@ -231,7 +231,7 @@ module CompletionKit
|
|
|
231
231
|
end
|
|
232
232
|
|
|
233
233
|
def render_engine_partial(partial, locals)
|
|
234
|
-
CompletionKit::Engine.
|
|
234
|
+
CompletionKit::Engine.warm_routes!
|
|
235
235
|
CompletionKit::ApplicationController.render(
|
|
236
236
|
partial: partial,
|
|
237
237
|
locals: locals
|
|
@@ -7,6 +7,21 @@ module CompletionKit
|
|
|
7
7
|
|
|
8
8
|
paths.add "app/services", eager_load: true
|
|
9
9
|
|
|
10
|
+
ROUTES_WARMUP_LOCK = Mutex.new
|
|
11
|
+
@routes_warmed = false
|
|
12
|
+
|
|
13
|
+
# Materialise the engine's lazy route set once, single-threaded. Background
|
|
14
|
+
# worker threads that render engine partials for Turbo broadcasts otherwise
|
|
15
|
+
# race the lazy first-load and raise "undefined method 'run_response_path'"
|
|
16
|
+
# (production survives only because eager_load finalises routes at boot).
|
|
17
|
+
def self.warm_routes!
|
|
18
|
+
ROUTES_WARMUP_LOCK.synchronize do
|
|
19
|
+
return if @routes_warmed
|
|
20
|
+
routes.url_helpers.root_path
|
|
21
|
+
@routes_warmed = true
|
|
22
|
+
end
|
|
23
|
+
end
|
|
24
|
+
|
|
10
25
|
def self.register_assets(app)
|
|
11
26
|
app.config.assets.precompile += %w(
|
|
12
27
|
completion_kit/application.css
|