GeoBrowserModal.css 4.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221
  1. .geo-browser-modal .geo-toolbar {
  2. display: flex;
  3. align-items: center;
  4. gap: 8px;
  5. flex-wrap: wrap;
  6. margin-bottom: 12px;
  7. }
  8. .geo-browser-modal .geo-toolbar .ant-input-search {
  9. flex: 1;
  10. min-width: 180px;
  11. }
  12. .geo-browser-modal .geo-meta {
  13. margin-inline-start: auto;
  14. font-size: 12px;
  15. color: var(--ant-color-text-tertiary);
  16. font-variant-numeric: tabular-nums;
  17. }
  18. .geo-browser-modal .geo-columns {
  19. display: grid;
  20. grid-template-columns: minmax(240px, 340px) minmax(0, 1fr);
  21. gap: 12px;
  22. height: 440px;
  23. }
  24. /* Both panes are the same fixed height, and the pager sits on the pane's floor
  25. rather than under the last row, so neither the dialog nor its controls move
  26. as the user steps between categories with wildly different rule counts. */
  27. .geo-browser-modal .geo-panel {
  28. height: 100%;
  29. min-height: 0;
  30. display: flex;
  31. flex-direction: column;
  32. overflow: hidden;
  33. border: 1px solid var(--ant-color-border-secondary);
  34. border-radius: 8px;
  35. }
  36. .geo-browser-modal .geo-panel .ant-table-wrapper,
  37. .geo-browser-modal .geo-panel .ant-spin-nested-loading,
  38. .geo-browser-modal .geo-panel .ant-spin-container {
  39. display: flex;
  40. flex-direction: column;
  41. flex: 1;
  42. min-height: 0;
  43. width: 100%;
  44. }
  45. .geo-browser-modal .geo-panel .ant-table {
  46. flex: 1;
  47. min-height: 0;
  48. }
  49. /* The rules table fills whatever is left between the header and the pager
  50. instead of carrying a hardcoded scroll height, so there is no dead strip
  51. above the pager and short categories do not scroll needlessly. */
  52. .geo-browser-modal .geo-preview-body {
  53. flex: 1;
  54. min-height: 0;
  55. overflow-y: auto;
  56. }
  57. .geo-browser-modal .geo-pager {
  58. margin-top: auto;
  59. display: flex;
  60. align-items: center;
  61. justify-content: flex-end;
  62. flex-wrap: wrap;
  63. padding: 6px 12px;
  64. border-top: 1px solid var(--ant-color-border-secondary);
  65. font-variant-numeric: tabular-nums;
  66. }
  67. .geo-browser-modal .geo-pager .ant-pagination-total-text {
  68. font-size: 12px;
  69. color: var(--ant-color-text-tertiary);
  70. }
  71. .geo-browser-modal .geo-categories .ant-table-row {
  72. cursor: pointer;
  73. }
  74. .geo-browser-modal .geo-row-active > td {
  75. background: var(--ant-color-primary-bg);
  76. }
  77. .geo-browser-modal .geo-category {
  78. display: flex;
  79. flex-direction: column;
  80. gap: 2px;
  81. min-width: 0;
  82. }
  83. .geo-browser-modal .geo-code,
  84. .geo-browser-modal .geo-entry-value,
  85. .geo-browser-modal .geo-preview-title {
  86. font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  87. font-size: 13px;
  88. overflow: hidden;
  89. text-overflow: ellipsis;
  90. white-space: nowrap;
  91. }
  92. .geo-browser-modal .geo-attrs .ant-tag {
  93. font-size: 10px;
  94. line-height: 16px;
  95. margin-inline-end: 4px;
  96. padding-inline: 4px;
  97. }
  98. .geo-browser-modal .geo-count {
  99. font-variant-numeric: tabular-nums;
  100. color: var(--ant-color-text-tertiary);
  101. font-size: 12px;
  102. }
  103. .geo-browser-modal .geo-preview-head {
  104. display: flex;
  105. align-items: center;
  106. gap: 8px;
  107. padding: 8px 12px;
  108. border-bottom: 1px solid var(--ant-color-border-secondary);
  109. }
  110. /* The title is the part that gives way: without min-width it refuses to
  111. shrink, and the filter is pushed onto a second line instead of the long
  112. category name being clipped. */
  113. .geo-browser-modal .geo-preview-title {
  114. flex: 0 1 auto;
  115. min-width: 0;
  116. }
  117. .geo-browser-modal .geo-preview-head .ant-typography {
  118. flex: none;
  119. white-space: nowrap;
  120. }
  121. .geo-browser-modal .geo-entry-filter {
  122. flex: none;
  123. width: 200px;
  124. margin-inline-start: auto;
  125. }
  126. @media (max-width: 520px) {
  127. .geo-browser-modal .geo-preview-head {
  128. flex-wrap: wrap;
  129. }
  130. .geo-browser-modal .geo-entry-filter {
  131. width: 100%;
  132. }
  133. }
  134. .geo-browser-modal .geo-kind {
  135. font-size: 10px;
  136. text-transform: uppercase;
  137. letter-spacing: 0.04em;
  138. }
  139. .geo-browser-modal .geo-kind-full {
  140. color: var(--ant-color-success);
  141. }
  142. .geo-browser-modal .geo-kind-keyword {
  143. color: var(--ant-color-warning);
  144. }
  145. .geo-browser-modal .geo-kind-regexp {
  146. color: var(--ant-color-primary);
  147. }
  148. .geo-browser-modal .geo-placeholder {
  149. flex: 1;
  150. display: flex;
  151. align-items: center;
  152. justify-content: center;
  153. padding: 40px 20px;
  154. text-align: center;
  155. }
  156. .geo-browser-modal .geo-footer {
  157. display: flex;
  158. align-items: center;
  159. gap: 8px;
  160. flex-wrap: wrap;
  161. margin-top: 12px;
  162. padding-top: 12px;
  163. border-top: 1px solid var(--ant-color-border-secondary);
  164. }
  165. .geo-browser-modal .geo-chips {
  166. flex: 1;
  167. max-height: 76px;
  168. overflow-y: auto;
  169. }
  170. .geo-browser-modal .geo-selected-count {
  171. font-size: 12px;
  172. color: var(--ant-color-text-tertiary);
  173. font-variant-numeric: tabular-nums;
  174. white-space: nowrap;
  175. }
  176. @media (max-width: 720px) {
  177. .geo-browser-modal .geo-columns {
  178. grid-template-columns: minmax(0, 1fr);
  179. height: auto;
  180. }
  181. .geo-browser-modal .geo-panel {
  182. height: 320px;
  183. }
  184. }
  185. .geo-unknown-hint {
  186. display: block;
  187. margin-top: 4px;
  188. font-size: 12px;
  189. }