@youtyan/code-viewer 0.2.11 → 0.4.0

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.
package/web/style.css CHANGED
@@ -1148,7 +1148,8 @@ body.gdp-history-page #topbar .ref-pickers {
1148
1148
  transform-origin: left center;
1149
1149
  pointer-events: none;
1150
1150
  }
1151
- #history-filter {
1151
+ #history-filter,
1152
+ .history-filter {
1152
1153
  box-sizing: border-box;
1153
1154
  width: 100%;
1154
1155
  height: 32px;
@@ -1163,16 +1164,19 @@ body.gdp-history-page #topbar .ref-pickers {
1163
1164
  outline: none;
1164
1165
  transition: border-color 0.12s ease, background-color 0.12s ease, box-shadow 0.12s ease;
1165
1166
  }
1166
- #history-filter:hover {
1167
+ #history-filter:hover,
1168
+ .history-filter:hover {
1167
1169
  border-color: var(--border);
1168
1170
  background: var(--bg);
1169
1171
  }
1170
- #history-filter:focus {
1172
+ #history-filter:focus,
1173
+ .history-filter:focus {
1171
1174
  border-color: var(--accent);
1172
1175
  background: var(--bg);
1173
1176
  box-shadow: 0 0 0 3px var(--accent-muted);
1174
1177
  }
1175
- #history-filter::placeholder {
1178
+ #history-filter::placeholder,
1179
+ .history-filter::placeholder {
1176
1180
  color: var(--fg-subtle);
1177
1181
  opacity: 1;
1178
1182
  }
@@ -1185,7 +1189,8 @@ body.gdp-history-page #topbar .ref-pickers {
1185
1189
  color: var(--fg-muted);
1186
1190
  font-size: 12px;
1187
1191
  }
1188
- #history-list { list-style: none; margin: 0; padding: 0 0 24px; }
1192
+ #history-list,
1193
+ .history-list { list-style: none; margin: 0; padding: 0 0 24px; }
1189
1194
  .history-group {
1190
1195
  display: flex;
1191
1196
  align-items: center;
@@ -1207,7 +1212,8 @@ body.gdp-history-page #topbar .ref-pickers {
1207
1212
  border-radius: 2px;
1208
1213
  background: var(--accent);
1209
1214
  }
1210
- #history-list > .history-group:first-child { border-top: 0; }
1215
+ #history-list > .history-group:first-child,
1216
+ .history-list > .history-group:first-child { border-top: 0; }
1211
1217
  .history-item {
1212
1218
  padding: 8px 14px;
1213
1219
  cursor: pointer;
@@ -1247,8 +1253,10 @@ body.gdp-history-page #topbar .ref-pickers {
1247
1253
  color: var(--fg-muted);
1248
1254
  font-size: 12px;
1249
1255
  }
1250
- #history-sentinel { height: 1px; }
1251
- #history-commit-info {
1256
+ #history-sentinel,
1257
+ .history-sentinel { height: 1px; }
1258
+ #history-commit-info,
1259
+ .history-commit-info {
1252
1260
  display: none;
1253
1261
  margin: 0 0 16px;
1254
1262
  padding: 16px 20px 18px;
@@ -1256,8 +1264,10 @@ body.gdp-history-page #topbar .ref-pickers {
1256
1264
  border-radius: 8px;
1257
1265
  background: var(--bg-soft);
1258
1266
  }
1259
- body.gdp-history-page #history-commit-info:not([hidden]) { display: block; }
1260
- #history-commit-info .hci-head {
1267
+ body.gdp-history-page #history-commit-info:not([hidden]),
1268
+ .history-commit-info:not([hidden]) { display: block; }
1269
+ #history-commit-info .hci-head,
1270
+ .history-commit-info .hci-head {
1261
1271
  display: flex;
1262
1272
  flex-wrap: wrap;
1263
1273
  align-items: baseline;
@@ -1265,17 +1275,20 @@ body.gdp-history-page #history-commit-info:not([hidden]) { display: block; }
1265
1275
  color: var(--fg-muted);
1266
1276
  font-size: 12px;
1267
1277
  }
1268
- #history-commit-info .hci-sha {
1278
+ #history-commit-info .hci-sha,
1279
+ .history-commit-info .hci-sha {
1269
1280
  font-family: "Monaspace Neon", ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, "Liberation Mono", monospace;
1270
1281
  user-select: all;
1271
1282
  }
1272
- #history-commit-info .hci-subject {
1283
+ #history-commit-info .hci-subject,
1284
+ .history-commit-info .hci-subject {
1273
1285
  margin: 8px 0 0;
1274
1286
  font-size: 15px;
1275
1287
  line-height: 1.4;
1276
1288
  overflow-wrap: anywhere;
1277
1289
  }
1278
- #history-commit-info .hci-body {
1290
+ #history-commit-info .hci-body,
1291
+ .history-commit-info .hci-body {
1279
1292
  margin: 12px 0 0;
1280
1293
  padding: 0;
1281
1294
  background: transparent;
@@ -1286,20 +1299,88 @@ body.gdp-history-page #history-commit-info:not([hidden]) { display: block; }
1286
1299
  color: var(--fg-muted);
1287
1300
  overflow-wrap: anywhere;
1288
1301
  }
1289
- #history-commit-info .hci-body .gdp-markdown-preview {
1302
+ #history-commit-info .hci-body .gdp-markdown-preview,
1303
+ .history-commit-info .hci-body .gdp-markdown-preview {
1290
1304
  color: inherit;
1291
1305
  font-size: inherit;
1292
1306
  line-height: inherit;
1293
1307
  }
1294
- #history-commit-info .hci-body .gdp-markdown-preview > :first-child {
1308
+ #history-commit-info .hci-body .gdp-markdown-preview > :first-child,
1309
+ .history-commit-info .hci-body .gdp-markdown-preview > :first-child {
1295
1310
  margin-top: 0;
1296
1311
  }
1297
- #history-commit-info .hci-body .gdp-markdown-preview > :last-child {
1312
+ #history-commit-info .hci-body .gdp-markdown-preview > :last-child,
1313
+ .history-commit-info .hci-body .gdp-markdown-preview > :last-child {
1298
1314
  margin-bottom: 0;
1299
1315
  }
1300
1316
  .hci-body-expandable {
1301
1317
  display: block;
1302
1318
  }
1319
+
1320
+ .gdp-standalone-file-history.gdp-file-shell {
1321
+ border: 0;
1322
+ border-radius: 0;
1323
+ box-shadow: none;
1324
+ background: transparent;
1325
+ content-visibility: visible;
1326
+ contain: none;
1327
+ contain-intrinsic-size: auto;
1328
+ }
1329
+ .gdp-file-history-body {
1330
+ padding: 0;
1331
+ }
1332
+ .gdp-file-history-embed {
1333
+ display: grid;
1334
+ grid-template-columns: minmax(260px, 320px) minmax(0, 1fr);
1335
+ min-height: calc(100vh - var(--global-header-h) - 92px);
1336
+ border-top: 1px solid var(--border);
1337
+ }
1338
+ .gdp-file-history-panel {
1339
+ min-width: 0;
1340
+ max-height: calc(100vh - var(--global-header-h) - 92px);
1341
+ overflow: auto;
1342
+ background: var(--bg-soft);
1343
+ border-right: 1px solid var(--border);
1344
+ }
1345
+ .gdp-file-history-diff-pane {
1346
+ min-width: 0;
1347
+ max-height: calc(100vh - var(--global-header-h) - 92px);
1348
+ overflow: auto;
1349
+ background: var(--bg);
1350
+ }
1351
+ .gdp-file-history-diff {
1352
+ min-width: 0;
1353
+ }
1354
+ .gdp-file-history-diff > .gdp-file-shell {
1355
+ margin: 0;
1356
+ border-left: 0;
1357
+ border-right: 0;
1358
+ border-radius: 0;
1359
+ }
1360
+ .gdp-file-history-diff .d2h-code-line,
1361
+ .gdp-file-history-diff .d2h-code-side-line,
1362
+ .gdp-file-history-diff .d2h-code-line-prefix,
1363
+ .gdp-file-history-diff .d2h-code-line-ctn,
1364
+ .gdp-file-history-diff .d2h-code-line-ctn *,
1365
+ .gdp-file-history-diff .d2h-code-linenumber,
1366
+ .gdp-file-history-diff .d2h-code-side-linenumber {
1367
+ font-size: var(--code-font-size) !important;
1368
+ }
1369
+ .gdp-file-history-empty {
1370
+ position: static;
1371
+ min-height: 280px;
1372
+ margin: 0;
1373
+ border: 0;
1374
+ border-radius: 0;
1375
+ box-shadow: none;
1376
+ }
1377
+ .gdp-file-history-commit-info {
1378
+ margin: 0;
1379
+ border-left: 0;
1380
+ border-right: 0;
1381
+ border-top: 0;
1382
+ border-radius: 0;
1383
+ }
1303
1384
  .hci-body-collapsible {
1304
1385
  position: relative;
1305
1386
  max-height: calc(10em * 1.6 + 8px);
@@ -3860,13 +3941,16 @@ body.gdp-repo-page:not(.gdp-sidebar-hidden) .gdp-repo-toolbar > .ref-selector,
3860
3941
  body.gdp-file-detail-page.gdp-repo-blob-page:not(.gdp-sidebar-hidden) .gdp-file-detail-header > .ref-selector {
3861
3942
  display: none;
3862
3943
  }
3863
- body.gdp-file-detail-page #diff > .gdp-file-shell:not(.gdp-standalone-source),
3944
+ body.gdp-file-detail-page
3945
+ #diff
3946
+ > .gdp-file-shell:not(.gdp-standalone-source):not(.gdp-standalone-blame):not(.gdp-standalone-file-history),
3864
3947
  body.gdp-file-detail-page #diff > .gdp-repo-shell,
3865
3948
  body.gdp-file-detail-page #empty {
3866
3949
  display: none !important;
3867
3950
  }
3868
3951
 
3869
- .gdp-repo-blob-layout .gdp-standalone-source {
3952
+ .gdp-repo-blob-layout .gdp-standalone-source,
3953
+ .gdp-repo-blob-layout .gdp-standalone-file-history {
3870
3954
  min-width: 0;
3871
3955
  }
3872
3956
 
@@ -4027,7 +4111,7 @@ body.gdp-file-detail-page #empty {
4027
4111
  .gdp-context-menu .danger {
4028
4112
  color: var(--danger);
4029
4113
  }
4030
- .gdp-trash-dialog-backdrop {
4114
+ .gdp-dialog-backdrop {
4031
4115
  position: fixed;
4032
4116
  inset: 0;
4033
4117
  z-index: 1100;
@@ -4037,30 +4121,30 @@ body.gdp-file-detail-page #empty {
4037
4121
  padding-top: min(14vh, 120px);
4038
4122
  background: rgba(31, 35, 40, 0.18);
4039
4123
  }
4040
- [data-theme="dark"] .gdp-trash-dialog-backdrop {
4124
+ [data-theme="dark"] .gdp-dialog-backdrop {
4041
4125
  background: rgba(1, 4, 9, 0.45);
4042
4126
  }
4043
- .gdp-trash-dialog {
4127
+ .gdp-dialog {
4044
4128
  width: min(420px, calc(100vw - 32px));
4045
4129
  border: 1px solid var(--border);
4046
4130
  border-radius: 8px;
4047
4131
  background: var(--bg);
4048
4132
  box-shadow: 0 16px 48px rgba(31, 35, 40, 0.28);
4049
4133
  }
4050
- .gdp-trash-dialog-title {
4134
+ .gdp-dialog-title {
4051
4135
  padding: 14px 16px 0;
4052
4136
  color: var(--fg);
4053
4137
  font-size: 15px;
4054
4138
  font-weight: 600;
4055
4139
  }
4056
- .gdp-trash-dialog-body {
4140
+ .gdp-dialog-body {
4057
4141
  padding: 8px 16px 14px;
4058
4142
  color: var(--fg-muted);
4059
4143
  font-size: 13px;
4060
4144
  line-height: 1.5;
4061
4145
  overflow-wrap: anywhere;
4062
4146
  }
4063
- .gdp-create-dir-input {
4147
+ .gdp-dialog-input {
4064
4148
  display: block;
4065
4149
  width: 100%;
4066
4150
  height: 32px;
@@ -4072,29 +4156,29 @@ body.gdp-file-detail-page #empty {
4072
4156
  color: var(--fg);
4073
4157
  font: inherit;
4074
4158
  }
4075
- .gdp-create-dir-input:focus {
4159
+ .gdp-dialog-input:focus {
4076
4160
  outline: 2px solid var(--accent-subtle);
4077
4161
  border-color: var(--accent);
4078
4162
  }
4079
- .gdp-create-dir-error {
4163
+ .gdp-dialog-error {
4080
4164
  min-height: 18px;
4081
4165
  margin-top: 6px;
4082
4166
  color: var(--danger);
4083
4167
  font-size: 12px;
4084
4168
  line-height: 18px;
4085
4169
  }
4086
- .gdp-trash-dialog-actions {
4170
+ .gdp-dialog-actions {
4087
4171
  display: flex;
4088
4172
  justify-content: flex-end;
4089
4173
  gap: 8px;
4090
4174
  padding: 12px 16px;
4091
4175
  border-top: 1px solid var(--border);
4092
4176
  }
4093
- .gdp-trash-dialog-danger {
4177
+ .gdp-dialog-danger {
4094
4178
  border-color: var(--danger);
4095
4179
  color: var(--danger);
4096
4180
  }
4097
- .gdp-trash-dialog-danger:hover {
4181
+ .gdp-dialog-danger:hover {
4098
4182
  background: var(--diff-del-bg);
4099
4183
  }
4100
4184
  .gdp-repo-empty {
@@ -4769,6 +4853,246 @@ body.query-history-panel-open #content {
4769
4853
  flex: 1;
4770
4854
  overflow-y: auto;
4771
4855
  }
4856
+ /* JetBrains 風 bottom dock。「クエリ履歴 / ログ」のタブストリップは pane の
4857
+ 開閉に関わらず常時表示し、画面下端に張り付く。タブクリックで pane を開閉
4858
+ する (アクティブタブ再クリックで閉じる)。右端の × でも閉じる。 */
4859
+ .db-history-dock {
4860
+ display: flex;
4861
+ align-items: stretch;
4862
+ gap: 0;
4863
+ min-height: 28px;
4864
+ border-top: 1px solid var(--border);
4865
+ background: var(--bg-soft);
4866
+ flex-shrink: 0;
4867
+ font-size: 12px;
4868
+ }
4869
+ .db-history-dock-tab {
4870
+ appearance: none;
4871
+ border: none;
4872
+ background: transparent;
4873
+ color: var(--fg-muted);
4874
+ font-family: inherit;
4875
+ font-size: inherit;
4876
+ padding: 0 14px;
4877
+ cursor: pointer;
4878
+ box-shadow: inset 0 2px 0 transparent;
4879
+ }
4880
+ .db-history-dock-tab:hover {
4881
+ background: var(--bg-mute);
4882
+ color: var(--fg);
4883
+ }
4884
+ /* active タブ: 上線 (accent) で「この pane を表示中」を示す。pane が閉じて
4885
+ いるときも「最後に開いていたタブ」がうっすら active のままだと混乱するので、
4886
+ dock.open が付いてるときだけ accent を強調する。 */
4887
+ .db-history-dock-tab.active {
4888
+ color: var(--fg);
4889
+ font-weight: 600;
4890
+ }
4891
+ .db-history-dock.open .db-history-dock-tab.active {
4892
+ color: var(--accent);
4893
+ box-shadow: inset 0 2px 0 var(--accent);
4894
+ }
4895
+ .db-history-dock-spacer {
4896
+ flex: 1;
4897
+ }
4898
+ .db-history-dock-close {
4899
+ appearance: none;
4900
+ border: none;
4901
+ background: transparent;
4902
+ color: var(--fg-muted);
4903
+ font-family: inherit;
4904
+ font-size: 14px;
4905
+ line-height: 1;
4906
+ padding: 0 10px;
4907
+ cursor: pointer;
4908
+ }
4909
+ .db-history-dock-close:hover {
4910
+ background: var(--bg-mute);
4911
+ color: var(--fg);
4912
+ }
4913
+ /* pane が閉じてるときは close ボタンも意味が無いので隠す。 */
4914
+ .db-history-dock:not(.open) .db-history-dock-close {
4915
+ visibility: hidden;
4916
+ }
4917
+ .db-history-pane-content {
4918
+ flex: 1;
4919
+ display: flex;
4920
+ flex-direction: column;
4921
+ overflow: hidden;
4922
+ }
4923
+ .db-history-pane-content[hidden] { display: none; }
4924
+ /* Session ログのレイアウト: クエリ履歴と同じ列構成。CSS は共通化せず、別系統
4925
+ として持つ (将来ストアやヘッダ構成が分岐しても影響を局所化できるように)。 */
4926
+ .db-session-log {
4927
+ height: 100%;
4928
+ display: flex;
4929
+ flex-direction: column;
4930
+ }
4931
+ .db-session-log-toolbar {
4932
+ display: flex;
4933
+ gap: 8px;
4934
+ padding: 8px 12px;
4935
+ border-bottom: 1px solid var(--border);
4936
+ }
4937
+ .db-session-log-action {
4938
+ padding: 4px 10px;
4939
+ border: 1px solid var(--border);
4940
+ border-radius: 4px;
4941
+ background: var(--bg);
4942
+ color: var(--fg);
4943
+ font-size: 12px;
4944
+ cursor: pointer;
4945
+ font-family: inherit;
4946
+ }
4947
+ .db-session-log-action:hover {
4948
+ background: var(--bg-mute);
4949
+ }
4950
+ /* 自動追従トグル ON 中の active 状態 (db-tool-btn.active と同じ accent 配色)。 */
4951
+ .db-session-log-action.active {
4952
+ background: color-mix(in srgb, var(--accent) 12%, var(--bg));
4953
+ color: var(--accent);
4954
+ border-color: var(--accent);
4955
+ font-weight: 600;
4956
+ }
4957
+ .db-session-log-danger {
4958
+ color: var(--danger, #d32f2f);
4959
+ }
4960
+ .db-session-log-body-split {
4961
+ flex: 1;
4962
+ display: flex;
4963
+ overflow: hidden;
4964
+ }
4965
+ .db-session-log-list-col {
4966
+ width: 360px;
4967
+ min-width: 260px;
4968
+ max-width: 500px;
4969
+ border-right: 1px solid var(--border);
4970
+ display: flex;
4971
+ flex-direction: column;
4972
+ overflow: hidden;
4973
+ }
4974
+ .db-session-log-detail-col {
4975
+ flex: 1;
4976
+ overflow-y: auto;
4977
+ padding: 12px;
4978
+ }
4979
+ .db-session-log-detail-placeholder,
4980
+ .db-session-log-empty {
4981
+ color: var(--fg-muted);
4982
+ text-align: center;
4983
+ padding: 40px 16px;
4984
+ font-size: 13px;
4985
+ }
4986
+ .db-session-log-detail-actions {
4987
+ display: flex;
4988
+ gap: 8px;
4989
+ margin-bottom: 12px;
4990
+ }
4991
+ .db-session-log-list {
4992
+ flex: 1;
4993
+ overflow-y: auto;
4994
+ }
4995
+ .db-session-log-entry {
4996
+ padding: 8px 12px;
4997
+ border-bottom: 1px solid var(--border);
4998
+ cursor: pointer;
4999
+ }
5000
+ .db-session-log-entry:hover {
5001
+ background: var(--bg-mute);
5002
+ }
5003
+ .db-session-log-entry.selected {
5004
+ background: color-mix(in srgb, var(--accent) 12%, var(--bg));
5005
+ border-left: 3px solid var(--accent);
5006
+ padding-left: 9px;
5007
+ }
5008
+ .db-session-log-entry-meta {
5009
+ display: flex;
5010
+ gap: 8px;
5011
+ align-items: center;
5012
+ font-size: 11px;
5013
+ color: var(--fg-muted);
5014
+ }
5015
+ .db-session-log-badge {
5016
+ font-weight: 600;
5017
+ font-size: 10px;
5018
+ padding: 1px 6px;
5019
+ border-radius: 999px;
5020
+ border: 1px solid transparent;
5021
+ }
5022
+ .db-session-log-badge-ok {
5023
+ background: rgba(46, 160, 67, 0.15);
5024
+ border-color: rgba(46, 160, 67, 0.4);
5025
+ color: var(--success, #2da44e);
5026
+ }
5027
+ .db-session-log-badge-error {
5028
+ background: rgba(207, 34, 46, 0.15);
5029
+ border-color: rgba(207, 34, 46, 0.4);
5030
+ color: var(--danger, #cf222e);
5031
+ }
5032
+ .db-session-log-kind {
5033
+ font-size: 10px;
5034
+ text-transform: uppercase;
5035
+ letter-spacing: 0.05em;
5036
+ color: var(--fg-subtle);
5037
+ }
5038
+ .db-session-log-time {
5039
+ font-size: 11px;
5040
+ }
5041
+ .db-session-log-stats {
5042
+ font-size: 11px;
5043
+ }
5044
+ .db-session-log-entry-title {
5045
+ margin-top: 4px;
5046
+ font-size: 12px;
5047
+ font-family: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, monospace;
5048
+ white-space: nowrap;
5049
+ overflow: hidden;
5050
+ text-overflow: ellipsis;
5051
+ }
5052
+ .db-session-log-sql {
5053
+ padding: 8px;
5054
+ border-radius: 4px;
5055
+ background: var(--bg);
5056
+ border: 1px solid var(--border);
5057
+ font-size: 12px;
5058
+ font-family: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, monospace;
5059
+ white-space: pre-wrap;
5060
+ word-break: break-word;
5061
+ margin-bottom: 8px;
5062
+ color: var(--fg);
5063
+ }
5064
+ /* shiki が `<span style="--shiki-light:#xxx;--shiki-dark:#yyy">` の inline
5065
+ CSS 変数で token ごとの色を出すので、light/dark 用にそれぞれ参照する。
5066
+ db-query-highlight と同じスキーム。 */
5067
+ .db-session-log-sql span[style] {
5068
+ color: var(--shiki-light);
5069
+ }
5070
+ @media (prefers-color-scheme: dark) {
5071
+ .db-session-log-sql span[style] {
5072
+ color: var(--shiki-dark);
5073
+ }
5074
+ }
5075
+ html[data-theme="dark"] .db-session-log-sql span[style] {
5076
+ color: var(--shiki-dark);
5077
+ }
5078
+ .db-session-log-message {
5079
+ padding: 8px;
5080
+ border-radius: 4px;
5081
+ font-size: 12px;
5082
+ font-family: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, monospace;
5083
+ white-space: pre-wrap;
5084
+ word-break: break-word;
5085
+ }
5086
+ .db-session-log-message-error {
5087
+ background: rgba(207, 34, 46, 0.08);
5088
+ border: 1px solid rgba(207, 34, 46, 0.4);
5089
+ color: var(--danger, #cf222e);
5090
+ }
5091
+ .db-session-log-message-ok {
5092
+ background: var(--bg-soft);
5093
+ border: 1px solid var(--border);
5094
+ color: var(--fg-muted);
5095
+ }
4772
5096
  .db-query-history {
4773
5097
  height: 100%;
4774
5098
  display: flex;
@@ -5639,31 +5963,6 @@ body[data-sidebar-font-size="xlarge"] .db-container {
5639
5963
  border-color: var(--accent);
5640
5964
  font-weight: 600;
5641
5965
  }
5642
- .db-history-toggle {
5643
- display: flex;
5644
- align-items: center;
5645
- gap: 6px;
5646
- width: 100%;
5647
- padding: 8px 12px;
5648
- border: none;
5649
- border-top: 1px solid var(--border);
5650
- background: var(--bg-soft);
5651
- color: var(--fg-muted);
5652
- font-size: var(--db-font-base);
5653
- font-family: inherit;
5654
- cursor: pointer;
5655
- text-align: left;
5656
- flex-shrink: 0;
5657
- }
5658
- .db-history-toggle:hover {
5659
- background: var(--bg-mute);
5660
- color: var(--fg);
5661
- }
5662
- .db-history-toggle.active {
5663
- color: var(--accent);
5664
- font-weight: 600;
5665
- }
5666
-
5667
5966
  /* ---------- [hidden] 属性を効かせる ---------- */
5668
5967
  /* `.db-*` クラスの多くが `display: flex` を主張しており、ブラウザ標準の
5669
5968
  `[hidden] { display: none }` (specificity 0,1,0) と CSS specificity が
@@ -5671,7 +5970,7 @@ body[data-sidebar-font-size="xlarge"] .db-container {
5671
5970
  .db-tools-section[hidden],
5672
5971
  .db-tool-btn[hidden],
5673
5972
  .db-tab-bar[hidden],
5674
- .db-history-toggle[hidden],
5973
+ .db-history-dock[hidden],
5675
5974
  .db-history-pane[hidden],
5676
5975
  .db-history-resizer[hidden],
5677
5976
  .db-table-list[hidden],
@@ -5851,36 +6150,113 @@ body[data-sidebar-font-size="xlarge"] .db-container {
5851
6150
  font-weight: 500;
5852
6151
  }
5853
6152
  .db-table-children {
5854
- padding-left: 20px;
6153
+ position: relative;
6154
+ margin: 1px 8px 6px 30px;
6155
+ padding: 2px 0 2px 10px;
6156
+ border-left: 1px solid color-mix(in srgb, var(--border) 82%, transparent);
6157
+ background: transparent;
5855
6158
  }
5856
6159
  .db-table-children[hidden] { display: none; }
5857
6160
  .db-table-col-item {
5858
- display: flex;
5859
- align-items: center;
5860
- gap: 6px;
5861
- padding: 2px 8px;
6161
+ display: block;
6162
+ padding: 5px 2px 6px 0;
6163
+ border-radius: 0;
5862
6164
  font-size: var(--db-font-sm);
5863
6165
  color: var(--fg-muted);
6166
+ transition: background 0.12s ease;
6167
+ }
6168
+ .db-table-col-item + .db-table-col-item {
6169
+ border-top: 1px solid color-mix(in srgb, var(--border) 58%, transparent);
6170
+ }
6171
+ .db-table-col-item:hover {
6172
+ background: color-mix(in srgb, var(--bg-soft) 72%, transparent);
5864
6173
  }
5865
6174
  .db-table-col-item.pk {
5866
6175
  color: var(--fg);
5867
6176
  font-weight: 500;
5868
6177
  }
5869
- .db-table-col-item.pk .db-table-col-name::before {
5870
- content: "🔑 ";
5871
- font-size: 9px;
6178
+ .db-table-col-main {
6179
+ display: grid;
6180
+ grid-template-columns: minmax(0, 1fr) auto;
6181
+ align-items: center;
6182
+ gap: 8px;
6183
+ min-width: 0;
5872
6184
  }
5873
- .db-table-col-name {
5874
- flex: 1;
5875
- overflow: hidden;
6185
+ .db-table-col-name-wrap {
6186
+ display: inline-flex;
6187
+ align-items: center;
6188
+ gap: 4px;
6189
+ min-width: 0;
6190
+ }
6191
+ .db-table-col-key {
6192
+ flex: 0 0 auto;
6193
+ padding: 0 3px;
6194
+ border-radius: 3px;
6195
+ border: 1px solid color-mix(in srgb, var(--scope-accent) 55%, var(--border));
6196
+ color: var(--scope-accent);
6197
+ font-size: 9px;
6198
+ font-weight: 700;
6199
+ line-height: 1.3;
6200
+ }
6201
+ .db-table-col-name {
6202
+ min-width: 0;
6203
+ overflow: hidden;
5876
6204
  text-overflow: ellipsis;
5877
6205
  white-space: nowrap;
6206
+ color: var(--fg);
6207
+ font-weight: 600;
6208
+ }
6209
+ .db-table-col-copy {
6210
+ flex: 0 0 18px;
6211
+ width: 18px;
6212
+ height: 18px;
6213
+ border-radius: 4px;
6214
+ opacity: 0.48;
6215
+ color: var(--fg-subtle);
6216
+ transition: background-color 0.12s, color 0.12s, opacity 0.12s;
6217
+ }
6218
+ .db-table-col-copy svg {
6219
+ width: 12px;
6220
+ height: 12px;
6221
+ }
6222
+ .db-table-col-item:hover .db-table-col-copy,
6223
+ .db-table-col-copy:focus-visible {
6224
+ opacity: 1;
6225
+ }
6226
+ .db-table-col-copy:hover {
6227
+ color: var(--accent);
6228
+ }
6229
+ .db-table-col-copy.copied {
6230
+ opacity: 1;
6231
+ color: var(--success);
6232
+ }
6233
+ .db-table-col-copy.failed {
6234
+ opacity: 1;
6235
+ color: var(--danger);
5878
6236
  }
5879
6237
  .db-table-col-type {
5880
- flex-shrink: 0;
6238
+ justify-self: end;
6239
+ max-width: 96px;
6240
+ padding: 1px 5px;
6241
+ border-radius: 999px;
6242
+ background: color-mix(in srgb, var(--bg-soft) 70%, transparent);
5881
6243
  font-size: var(--db-font-sm);
5882
6244
  color: var(--fg-subtle);
5883
6245
  font-family: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, monospace;
6246
+ overflow: hidden;
6247
+ text-overflow: ellipsis;
6248
+ white-space: nowrap;
6249
+ }
6250
+ .db-table-col-comment {
6251
+ display: -webkit-box;
6252
+ margin-top: 3px;
6253
+ color: var(--fg-muted);
6254
+ font-size: var(--db-font-sm);
6255
+ font-weight: 400;
6256
+ line-height: 1.4;
6257
+ -webkit-line-clamp: 2;
6258
+ -webkit-box-orient: vertical;
6259
+ overflow: hidden;
5884
6260
  }
5885
6261
 
5886
6262
  .db-table-icon {
@@ -6156,6 +6532,122 @@ body[data-sidebar-font-size="xlarge"] .db-container {
6156
6532
  flex-shrink: 0;
6157
6533
  }
6158
6534
 
6535
+ /* ---------- Row editing (edit / insert / delete) ---------- */
6536
+ .db-grid-edit-controls {
6537
+ display: flex;
6538
+ align-items: center;
6539
+ gap: 6px;
6540
+ flex-shrink: 0;
6541
+ }
6542
+ /* 編集モードがオンのトグルは accent で塗る (.controls > button.active と同系統)。 */
6543
+ .db-grid-edit-toggle.active {
6544
+ background: var(--accent);
6545
+ border-color: var(--accent);
6546
+ color: #fff;
6547
+ }
6548
+ .db-grid-edit-status {
6549
+ font-size: var(--db-font-sm);
6550
+ color: var(--fg-muted);
6551
+ white-space: nowrap;
6552
+ }
6553
+
6554
+ /* 編集セルは入力欄を全幅で内包する。 */
6555
+ .db-grid-cell-edit {
6556
+ padding: 0;
6557
+ position: relative;
6558
+ }
6559
+ /* 編集モードでも既定は read-only と同じ見た目の表示モード。
6560
+ ダブルクリックで input になることを薄い枠で示す。 */
6561
+ .db-grid-cell-edit.db-grid-cell-display {
6562
+ padding: 4px 8px;
6563
+ white-space: nowrap;
6564
+ overflow: hidden;
6565
+ text-overflow: ellipsis;
6566
+ }
6567
+ .db-grid-cell-edit.db-grid-cell-display:not(.readonly):hover {
6568
+ outline: 1px dashed var(--border);
6569
+ outline-offset: -2px;
6570
+ }
6571
+ .db-grid-cell-edit.db-grid-cell-display.readonly {
6572
+ color: var(--fg-subtle);
6573
+ background: rgba(128, 128, 128, 0.06);
6574
+ }
6575
+ /* NULL 状態の入力欄は placeholder "NULL" を斜体・淡色で示す。 */
6576
+ .db-grid-cell-input.is-null::placeholder {
6577
+ color: var(--fg-subtle);
6578
+ font-style: italic;
6579
+ opacity: 1;
6580
+ }
6581
+ /* セル右端の「NULL にする」ボタン。ホバー時のみ目立たせる。 */
6582
+ .db-grid-cell-null-btn {
6583
+ position: absolute;
6584
+ top: 50%;
6585
+ right: 2px;
6586
+ transform: translateY(-50%);
6587
+ border: none;
6588
+ background: transparent;
6589
+ color: var(--fg-subtle);
6590
+ cursor: pointer;
6591
+ font-size: 12px;
6592
+ line-height: 1;
6593
+ padding: 2px 4px;
6594
+ border-radius: 3px;
6595
+ }
6596
+ .db-grid-cell-null-btn:hover {
6597
+ color: var(--fg);
6598
+ background: var(--bg-soft);
6599
+ }
6600
+ .db-grid-cell-input {
6601
+ width: 100%;
6602
+ height: 100%;
6603
+ box-sizing: border-box;
6604
+ border: none;
6605
+ background: transparent;
6606
+ color: var(--fg);
6607
+ font: inherit;
6608
+ padding: 4px 8px;
6609
+ }
6610
+ .db-grid-cell-input:focus {
6611
+ outline: 2px solid var(--accent);
6612
+ outline-offset: -2px;
6613
+ background: var(--bg);
6614
+ }
6615
+ .db-grid-cell-input.readonly {
6616
+ color: var(--fg-subtle);
6617
+ background: rgba(128, 128, 128, 0.06);
6618
+ }
6619
+
6620
+ /* 削除マーク済みの行は取り消し線+赤系で示す。 */
6621
+ .db-grid-row-deleted {
6622
+ background: rgba(207, 34, 46, 0.08);
6623
+ text-decoration: line-through;
6624
+ opacity: 0.7;
6625
+ }
6626
+ /* 新規行ドラフトは accent 系で「未保存」を示す。 */
6627
+ .db-grid-row-draft {
6628
+ background: var(--accent-subtle);
6629
+ }
6630
+ /* 値を編集 (未コミット) した行は黄系の薄背景。delete マークが優先するため
6631
+ :not で除外。draft 行とも干渉しないよう個別 selector で十分。 */
6632
+ .db-grid-row-edited:not(.db-grid-row-deleted) {
6633
+ background: rgba(210, 153, 34, 0.10);
6634
+ }
6635
+ /* 編集したセル単体は同系のやや濃い背景 + 左端に縦バーで「ここを変更」と
6636
+ 示す。display モードと input モードの両方で適用する。 */
6637
+ .db-grid-cell-edited {
6638
+ background: rgba(210, 153, 34, 0.22);
6639
+ box-shadow: inset 2px 0 0 var(--attn);
6640
+ }
6641
+ .db-grid-rownum-deletable:hover {
6642
+ color: var(--danger);
6643
+ background: rgba(207, 34, 46, 0.12);
6644
+ }
6645
+ .db-grid-rownum-draft {
6646
+ color: var(--accent);
6647
+ font-weight: 600;
6648
+ text-align: center;
6649
+ }
6650
+
6159
6651
  /* ---------- Query Editor ---------- */
6160
6652
  .db-query-editor {
6161
6653
  flex: 1;
@@ -6367,6 +6859,17 @@ html[data-theme="dark"] .db-query-highlight span[style] {
6367
6859
  .db-schema-table tr.pk-row {
6368
6860
  background: var(--attention-subtle, #fff8c5);
6369
6861
  }
6862
+ /* ダークモードでは淡黄色だと白文字とのコントラストがきつく目が痛い。
6863
+ accent を低彩度の背景タイルとして敷く (db-tool-btn.active と同じ
6864
+ color-mix スキーム)。 */
6865
+ @media (prefers-color-scheme: dark) {
6866
+ .db-schema-table tr.pk-row {
6867
+ background: color-mix(in srgb, var(--accent) 18%, transparent);
6868
+ }
6869
+ }
6870
+ html[data-theme="dark"] .db-schema-table tr.pk-row {
6871
+ background: color-mix(in srgb, var(--accent) 18%, transparent);
6872
+ }
6370
6873
 
6371
6874
  .db-schema-col-name {
6372
6875
  font-family: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, monospace;
@@ -6385,6 +6888,13 @@ html[data-theme="dark"] .db-query-highlight span[style] {
6385
6888
  color: var(--fg-subtle);
6386
6889
  font-size: var(--db-font-base);
6387
6890
  }
6891
+ .db-schema-comment {
6892
+ color: var(--fg-muted);
6893
+ line-height: 1.35;
6894
+ min-width: 180px;
6895
+ max-width: 420px;
6896
+ white-space: normal;
6897
+ }
6388
6898
 
6389
6899
  /* ---------- Data Grid: Filter Bar ---------- */
6390
6900
  .db-grid-filter-bar {
@@ -7907,6 +8417,58 @@ body.db-resizing {
7907
8417
  text-overflow: ellipsis;
7908
8418
  white-space: nowrap;
7909
8419
  }
8420
+ /* 値編集アクション (Edit / Delete) はヘッダ右端に寄せる。 */
8421
+ .redis-value-actions {
8422
+ margin-left: auto;
8423
+ display: flex;
8424
+ gap: 6px;
8425
+ flex-shrink: 0;
8426
+ }
8427
+ /* キーリストヘッダ: タイトル + 新規キーボタン。 */
8428
+ .redis-key-list-header {
8429
+ display: flex;
8430
+ align-items: center;
8431
+ justify-content: space-between;
8432
+ gap: 8px;
8433
+ }
8434
+ /* 値編集 / 新規キーフォーム。 */
8435
+ .redis-value-edit-bar {
8436
+ display: flex;
8437
+ align-items: center;
8438
+ gap: 6px;
8439
+ margin-bottom: 6px;
8440
+ }
8441
+ .redis-value-edit-status {
8442
+ font-size: var(--db-font-sm);
8443
+ color: var(--fg-muted);
8444
+ }
8445
+ .redis-value-edit-textarea,
8446
+ .redis-new-key-value {
8447
+ width: 100%;
8448
+ min-height: 160px;
8449
+ box-sizing: border-box;
8450
+ font-family: var(--mono, monospace);
8451
+ font-size: var(--db-font-mono);
8452
+ padding: 8px;
8453
+ border: 1px solid var(--border);
8454
+ border-radius: 4px;
8455
+ background: var(--bg);
8456
+ color: var(--fg);
8457
+ resize: vertical;
8458
+ }
8459
+ .redis-new-key-form {
8460
+ display: flex;
8461
+ flex-direction: column;
8462
+ gap: 8px;
8463
+ }
8464
+ .redis-new-key-name {
8465
+ padding: 6px 8px;
8466
+ border: 1px solid var(--border);
8467
+ border-radius: 4px;
8468
+ background: var(--bg);
8469
+ color: var(--fg);
8470
+ font-family: var(--mono, monospace);
8471
+ }
7910
8472
  .redis-value-body {
7911
8473
  flex: 1;
7912
8474
  overflow: auto;
@@ -8219,6 +8781,9 @@ body.db-resizing {
8219
8781
  }
8220
8782
  .es-mapping-header,
8221
8783
  .es-doc-detail-header {
8784
+ display: flex;
8785
+ align-items: center;
8786
+ gap: 8px;
8222
8787
  font-family: var(--mono, monospace);
8223
8788
  font-size: var(--db-font-mono);
8224
8789
  font-weight: 600;
@@ -8226,6 +8791,54 @@ body.db-resizing {
8226
8791
  border-bottom: 1px solid var(--border);
8227
8792
  margin-bottom: 8px;
8228
8793
  }
8794
+ .es-doc-actions {
8795
+ margin-left: auto;
8796
+ display: flex;
8797
+ gap: 6px;
8798
+ flex-shrink: 0;
8799
+ }
8800
+ .es-doc-list-header {
8801
+ display: flex;
8802
+ align-items: center;
8803
+ justify-content: space-between;
8804
+ gap: 8px;
8805
+ }
8806
+ .es-doc-edit-bar {
8807
+ display: flex;
8808
+ align-items: center;
8809
+ gap: 6px;
8810
+ margin-bottom: 6px;
8811
+ }
8812
+ .es-doc-edit-status {
8813
+ font-size: var(--db-font-sm);
8814
+ color: var(--fg-muted);
8815
+ }
8816
+ .es-doc-edit-textarea {
8817
+ width: 100%;
8818
+ min-height: 280px;
8819
+ box-sizing: border-box;
8820
+ font-family: var(--mono, monospace);
8821
+ font-size: var(--db-font-mono);
8822
+ padding: 8px;
8823
+ border: 1px solid var(--border);
8824
+ border-radius: 4px;
8825
+ background: var(--bg);
8826
+ color: var(--fg);
8827
+ resize: vertical;
8828
+ }
8829
+ .es-new-doc-form {
8830
+ display: flex;
8831
+ flex-direction: column;
8832
+ gap: 8px;
8833
+ }
8834
+ .es-new-doc-id {
8835
+ padding: 6px 8px;
8836
+ border: 1px solid var(--border);
8837
+ border-radius: 4px;
8838
+ background: var(--bg);
8839
+ color: var(--fg);
8840
+ font-family: var(--mono, monospace);
8841
+ }
8229
8842
  .es-doc-detail-meta {
8230
8843
  font-family: var(--mono, monospace);
8231
8844
  font-size: var(--db-font-sm);
@@ -8735,6 +9348,45 @@ body.db-resizing {
8735
9348
  display: flex;
8736
9349
  align-items: center;
8737
9350
  gap: 6px;
9351
+ flex-wrap: wrap;
9352
+ }
9353
+ /* オブジェクト編集 / 新規作成フォーム。 */
9354
+ .s3-edit-bar {
9355
+ display: flex;
9356
+ align-items: center;
9357
+ gap: 6px;
9358
+ margin-bottom: 6px;
9359
+ }
9360
+ .s3-edit-status {
9361
+ font-size: var(--db-font-sm);
9362
+ color: var(--fg-muted);
9363
+ }
9364
+ .s3-edit-textarea {
9365
+ width: 100%;
9366
+ min-height: 280px;
9367
+ box-sizing: border-box;
9368
+ font-family: var(--mono, monospace);
9369
+ font-size: var(--db-font-mono);
9370
+ padding: 8px;
9371
+ border: 1px solid var(--border);
9372
+ border-radius: 4px;
9373
+ background: var(--bg);
9374
+ color: var(--fg);
9375
+ resize: vertical;
9376
+ }
9377
+ .s3-new-object-form {
9378
+ display: flex;
9379
+ flex-direction: column;
9380
+ gap: 8px;
9381
+ padding: 12px;
9382
+ }
9383
+ .s3-new-object-key {
9384
+ padding: 6px 8px;
9385
+ border: 1px solid var(--border);
9386
+ border-radius: 4px;
9387
+ background: var(--bg);
9388
+ color: var(--fg);
9389
+ font-family: var(--mono, monospace);
8738
9390
  }
8739
9391
  .s3-preview-body {
8740
9392
  flex: 1;
@@ -8901,4 +9553,149 @@ body.db-resizing {
8901
9553
  .db-tab-host > .db-container[hidden] {
8902
9554
  display: none;
8903
9555
  }
8904
-
9556
+
9557
+ /* ---------- Blame view (web-src/views/blame-view.ts) ---------- */
9558
+ .gdp-standalone-blame.gdp-file-shell {
9559
+ --blame-bin-0: #ffeedf;
9560
+ --blame-bin-1: #ffd9b8;
9561
+ --blame-bin-2: #ffb47a;
9562
+ --blame-bin-3: #ff8c3b;
9563
+ --blame-bin-4: #d9590a;
9564
+ --blame-uncommitted: #ffa50066;
9565
+ content-visibility: visible;
9566
+ contain: none;
9567
+ contain-intrinsic-size: auto;
9568
+ }
9569
+ :root.dark .gdp-standalone-blame,
9570
+ .gdp-standalone-blame.dark {
9571
+ --blame-bin-0: #4a2f1c;
9572
+ --blame-bin-1: #6b3e1d;
9573
+ --blame-bin-2: #8a4d1f;
9574
+ --blame-bin-3: #b95f1f;
9575
+ --blame-bin-4: #f08a3a;
9576
+ }
9577
+ .gdp-blame-legend {
9578
+ display: inline-flex;
9579
+ align-items: center;
9580
+ gap: 6px;
9581
+ padding: 4px 12px 8px;
9582
+ font-size: 12px;
9583
+ color: var(--fg-muted);
9584
+ }
9585
+ .gdp-blame-legend-stops {
9586
+ display: inline-flex;
9587
+ gap: 2px;
9588
+ }
9589
+ .gdp-blame-legend-stop {
9590
+ width: 14px;
9591
+ height: 10px;
9592
+ border-radius: 2px;
9593
+ background: var(--blame-bin-0);
9594
+ }
9595
+ .gdp-blame-legend-stop[data-bin="1"] {
9596
+ background: var(--blame-bin-1);
9597
+ }
9598
+ .gdp-blame-legend-stop[data-bin="2"] {
9599
+ background: var(--blame-bin-2);
9600
+ }
9601
+ .gdp-blame-legend-stop[data-bin="3"] {
9602
+ background: var(--blame-bin-3);
9603
+ }
9604
+ .gdp-blame-legend-stop[data-bin="4"] {
9605
+ background: var(--blame-bin-4);
9606
+ }
9607
+ .gdp-blame-body {
9608
+ overflow: auto;
9609
+ }
9610
+ .gdp-blame-table {
9611
+ min-width: 100%;
9612
+ }
9613
+ .gdp-standalone-blame .gdp-source-table,
9614
+ .gdp-standalone-blame .gdp-source-line-number,
9615
+ .gdp-standalone-blame .gdp-source-line-code,
9616
+ .gdp-standalone-blame .gdp-source-line-code code,
9617
+ .gdp-standalone-blame .gdp-source-line-code span {
9618
+ font-size: var(--code-font-size) !important;
9619
+ }
9620
+ .gdp-blame-row {
9621
+ vertical-align: top;
9622
+ }
9623
+ .gdp-blame-row:hover .gdp-source-line-code {
9624
+ background: var(--bg-soft);
9625
+ }
9626
+ .gdp-blame-info {
9627
+ width: 240px;
9628
+ min-width: 240px;
9629
+ max-width: 320px;
9630
+ padding: 4px 8px 4px 0;
9631
+ border-top: 1px solid var(--border);
9632
+ border-right: 1px solid var(--border);
9633
+ position: relative;
9634
+ background: var(--bg);
9635
+ }
9636
+ .gdp-blame-bar {
9637
+ position: absolute;
9638
+ left: 0;
9639
+ top: 0;
9640
+ bottom: 0;
9641
+ width: 4px;
9642
+ background: var(--blame-bin-0);
9643
+ }
9644
+ .gdp-blame-bar[data-bin="1"] {
9645
+ background: var(--blame-bin-1);
9646
+ }
9647
+ .gdp-blame-bar[data-bin="2"] {
9648
+ background: var(--blame-bin-2);
9649
+ }
9650
+ .gdp-blame-bar[data-bin="3"] {
9651
+ background: var(--blame-bin-3);
9652
+ }
9653
+ .gdp-blame-bar[data-bin="4"] {
9654
+ background: var(--blame-bin-4);
9655
+ }
9656
+ .gdp-blame-bar.uncommitted {
9657
+ background: var(--blame-uncommitted);
9658
+ }
9659
+ .gdp-blame-info > .gdp-blame-meta,
9660
+ .gdp-blame-info > .gdp-blame-summary {
9661
+ padding-left: 10px;
9662
+ }
9663
+ .gdp-blame-meta {
9664
+ display: flex;
9665
+ gap: 8px;
9666
+ align-items: baseline;
9667
+ color: var(--fg-muted);
9668
+ font-size: 11px;
9669
+ }
9670
+ .gdp-blame-time {
9671
+ color: var(--fg);
9672
+ font-weight: 500;
9673
+ }
9674
+ .gdp-blame-author {
9675
+ white-space: nowrap;
9676
+ overflow: hidden;
9677
+ text-overflow: ellipsis;
9678
+ max-width: 96px;
9679
+ }
9680
+ .gdp-blame-sha {
9681
+ margin-left: auto;
9682
+ font-family: var(--monospace, ui-monospace, SFMono-Regular, monospace);
9683
+ color: var(--fg-muted);
9684
+ }
9685
+ .gdp-blame-summary {
9686
+ color: var(--fg);
9687
+ font-size: 12px;
9688
+ white-space: nowrap;
9689
+ overflow: hidden;
9690
+ text-overflow: ellipsis;
9691
+ margin-top: 2px;
9692
+ }
9693
+ .gdp-blame-loading,
9694
+ .gdp-blame-error {
9695
+ padding: 16px;
9696
+ color: var(--fg-muted);
9697
+ font-size: 13px;
9698
+ }
9699
+ .gdp-blame-error {
9700
+ color: var(--danger, #c33);
9701
+ }