PluginProbe
BetterDocs – AI Documentation, Knowledge Base, MCP Server, Docs, Wikis, FAQ & Chatbot / 4.9.5
BetterDocs – AI Documentation, Knowledge Base, MCP Server, Docs, Wikis, FAQ & Chatbot v4.9.5
4.9.5 4.9.4 4.9.3 4.9.2 4.9.1 4.9.0 4.8.2 4.8.1 4.8.0 4.7.0 4.6.2 4.6.1 4.6.0 4.5.6 4.5.5 4.5.4 4.5.3 4.5.2 4.5.1 4.5.0 4.4.1 4.4.0 3.3.4 3.4.0 3.4.1 All 203 releases
betterdocs / react-src / admin / scss / faq-builder / utils / _modal.scss

_modal.scss in BetterDocs – AI Documentation, Knowledge Base, MCP Server, Docs, Wikis, FAQ & Chatbot 4.9.5, at react-src/admin/scss/faq-builder/utils/_modal.scss

194 lines 6.4 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 // ===========================================================================
2 // Shared admin modal shell — "Generate sample docs" design language.
3 // One source of truth for every modal that uses the .bd-faq-ctg-modal markup
4 // (Create/Update FAQ Group, Write FAQ with AI, Define Glossaries with AI,
5 // Glossary AI, …). Header + footer are soft-gray bars; the card rounds at the
6 // top via the header and at the bottom via the footer.
7 //
8 // Reference tokens mapped onto the admin design system (so dark mode follows):
9 // green #00B884 → var(--base-color-700) border-soft #EEF0F3 → var(--text-color-150)
10 // ink #0F172A → var(--text-color-900) surface #FBFCFD → var(--text-color-50)
11 // muted #6B7280 → var(--text-color-600) close bg #F4F6F8 → var(--text-color-100)
12 // ===========================================================================
13 .bd-faq-ctg-modal {
14 font-family: "IBM Plex Sans", sans-serif;
15 // Positioned ancestor for the absolute close button (overrides the inline
16 // position:static ReactModal sets on the content node).
17 position: relative !important;
18
19 // --- Header bar ---------------------------------------------------------
20 .bd-faq-ctg-header {
21 background: var(--text-color-50);
22 border-bottom: 1px solid var(--text-color-150);
23 border-radius: 20px 20px 0 0;
24 display: flex;
25 align-items: center;
26 gap: 11px;
27 // Reserve room on the right for the in-header close button (32px square
28 // at right:22px) so long titles never run under it.
29 padding: 16px 64px 16px 22px;
30
31 // 32px rounded green-tinted badge; tint comes from the inline
32 // --bd-icon-tint vars the component sets. Icon glyph itself is
33 // untouched — only sized to 17px.
34 .bd-faq-stat-card__icon {
35 width: 32px;
36 height: 32px;
37 flex-shrink: 0;
38 display: flex;
39 align-items: center;
40 justify-content: center;
41 border-radius: 9px;
42 img,
43 svg {
44 width: 17px;
45 height: 17px;
46 }
47 }
48 .bd-faq-ctg-heading {
49 display: flex;
50 flex-direction: column;
51 gap: 1px;
52 min-width: 0;
53 flex: 1;
54 }
55 .bd-faq-ctg-title {
56 font-size: 18px;
57 font-weight: 600;
58 color: var(--text-color-900);
59 margin: 0;
60 line-height: 1.3;
61 }
62 .bd-faq-ctg-subtitle {
63 font-size: 12px;
64 font-weight: 400;
65 color: var(--text-color-600);
66 margin: 0;
67 line-height: 1.4;
68 }
69 }
70
71 // --- Close button (in-header, top-right) --------------------------------
72 .bd-faq-modal-close-button {
73 position: absolute;
74 top: 16px;
75 right: 22px;
76 z-index: 2;
77 width: 32px;
78 height: 32px;
79 display: inline-flex;
80 align-items: center;
81 justify-content: center;
82 border: none;
83 border-radius: 9px;
84 background: var(--text-color-100);
85 box-shadow: none !important;
86 color: var(--text-color-600);
87 cursor: pointer;
88 transition: all 0.2s ease-in-out;
89 // Only resize the existing glyph — never swap it.
90 img,
91 svg {
92 width: 16px;
93 height: 16px;
94 color: inherit;
95 fill: currentColor;
96 }
97 &:hover {
98 background: var(--text-color-200);
99 color: var(--text-color-900);
100 }
101 }
102
103 // --- Body ---------------------------------------------------------------
104 .bd-faq-ctg-body {
105 background: var(--base-background);
106 padding: 24px 26px;
107 display: flex;
108 flex-direction: column;
109 gap: 20px;
110
111 // Every field sits on white with the same soft 1px border as
112 // .bd-faq-input — selects ship a darker default border, so normalise it
113 // here (the input/textarea white fill is set inside the field block
114 // below, to win over the imported form partial's specificity).
115 .bd-faq-select__control {
116 background: var(--base-background);
117 border: 1px solid var(--text-color-150);
118 }
119
120 .bd-faq-cgt-field {
121 display: flex;
122 flex-direction: column;
123 gap: 10px;
124 @import "form";
125 .bd-faq-input,
126 .bd-faq-textarea {
127 background: var(--base-background);
128 border: 1px solid var(--text-color-150);
129 }
130 .bd-error-message {
131 font-size: 13px;
132 color: var(--danger-600);
133 margin: 0;
134 }
135 }
136 }
137
138 // --- Footer bar ---------------------------------------------------------
139 .bd-faq-ctg-footer {
140 background: var(--text-color-50);
141 border-top: 1px solid var(--text-color-150);
142 border-radius: 0 0 20px 20px;
143 padding: 16px 22px;
144 display: flex;
145 align-items: center;
146 column-gap: 12px;
147 row-gap: 10px;
148 flex-wrap: wrap;
149 justify-content: flex-end;
150 @import "button";
151
152 // Every footer button shares the same 13px label.
153 .bd-faq-button {
154 font-size: 13px;
155 }
156
157 // Secondary / "Maybe later" — borderless muted text, pinned left.
158 .bd-faq-button.button-cancel {
159 margin-right: auto;
160 min-height: 0;
161 padding: 8px 6px;
162 background: none;
163 border: none;
164 box-shadow: none;
165 font-weight: 600;
166 color: var(--text-color-600);
167 &:hover {
168 background: none;
169 color: var(--text-color-900);
170 }
171 }
172
173 // Primary — solid green pill with the reference's soft inner/outer
174 // highlight; the gap holds the (unchanged) leading icon at 16px.
175 .bd-faq-button.button-success {
176 gap: 8px;
177 padding: 9px 20px;
178 border-radius: 10px;
179 font-size: 13px;
180 font-weight: 600;
181 box-shadow: none;
182 transition: background 0.15s, transform 0.05s;
183 &:active {
184 transform: translateY(1px);
185 }
186 .bd-faq-icon img,
187 .bd-faq-icon svg {
188 width: 16px;
189 height: 16px;
190 }
191 }
192 }
193 }
194