File: users.scss

package info (click to toggle)
cockpit 239-1
  • links: PTS, VCS
  • area: main
  • in suites: bullseye
  • size: 67,268 kB
  • sloc: javascript: 245,474; ansic: 72,273; python: 23,634; xml: 6,155; sh: 2,919; makefile: 923; sed: 5
file content (253 lines) | stat: -rw-r--r-- 6,186 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
@import "../lib/page.scss";
@import "@patternfly/patternfly/components/DataList/data-list.scss";
@import "@patternfly/patternfly/components/Form/form.scss";
@import "../lib/table.css";
@import "../lib/ct-card.scss";

#account .pf-c-card {
    @extend .ct-card;

    // Make the header properly wrap
    &__header {
        flex-wrap: wrap;
        // WebKit and older versions of Chrome have issues with "gap" on flex
        // (but they'll just be a few pixels too close together)
        gap: var(--pf-global--spacer--sm) 0;
    }

    // Remove the gap from the actions...
    &__actions {
        margin-left: 0;
        padding-left: 0;
    }

    // And add the gap to the title
    &__title {
        flex: auto;
        margin-right: var(--pf-global--spacer--md);
    }
}

.account-details .pf-c-card__header {
    margin-bottom: var(--pf-global--spacer--lg);
}

#account {
    --pf-c-page__main-breadcrumb--PaddingBottom: var(--pf-c-page__main-breadcrumb--PaddingTop);
}

#account .pf-l-gallery {
    --pf-l-gallery--GridTemplateColumns: 1fr;
}

#account .pf-c-page__main-section,
#account .pf-c-page__main-nav {
    padding: var(--pf-global--gutter);
}

#accounts-list {
    --ct-account-pic-size: 3rem;
    display: grid;
    align-items: stretch;
    grid-gap: 0.5rem;
    margin: 2rem 0 0;
    grid-template-columns: repeat(auto-fit, minmax(calc(8rem + var(--ct-account-pic-size)), 1fr));
}

@media (max-width: 640px) {
    #accounts-list {
        --ct-account-pic-size: 0rem;
    }
}

.cockpit-account {
    align-content: center;
    background: var(--ct-color-bg);
    border: 1px solid var(--ct-color-border);
    box-shadow: 0px 1px 1px rgba(0, 0, 0, 0.05);
    display: grid;
    grid-template-areas: "pic name"
                         "pic account";
    grid-template-columns: var(--ct-account-pic-size) 1fr;
    grid-gap: 0 0.25rem;
    min-height: 4rem;
    padding: 0.5rem;
}

.cockpit-account:hover,
.cockpit-account:focus-within {
    background-color: var(--ct-color-link-hover-bg);
    cursor: pointer;
}

.cockpit-account > .cockpit-account-pic {
    font-size: var(--ct-account-pic-size);
    color: #bebebe;
    grid-area: pic;
}

.cockpit-account > .cockpit-account-real-name {
    font-weight: bold;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
    grid-area: name;
}

.cockpit-account > .cockpit-account-user-name {
    overflow: hidden;
    text-overflow: ellipsis;
    grid-area: account;
    /* We're using an underline on focus and focus-within above for focus indication */
    outline: none;

    > a {
        margin-right: 0.5rem;
    }
}

#account-details div.checkbox:first-child {
	margin-top: 0px;
}

#account-details div.checkbox:last-child {
	margin-bottom: 0px;
}

#account-pic {
    background: #d3d7cf;
    border-radius: 5px;
    cursor: pointer;
}

#account-authorized-keys {
    .pf-c-data-list__item {
        // Align text with heading
        --pf-c-data-list__item-row--PaddingLeft: var(--pf-global--spacer--lg);

        // Align - buttons with + button
        --pf-c-data-list__item-row--PaddingRight: var(--pf-global--spacer--md);

        // Add a border to the top item
        &:first-child {
            border-top: var(--pf-c-data-list__item--BorderBottomWidth) solid var(--pf-c-data-list__item--BorderBottomColor);
        }

        // Remove a border from the bottom item
        &:last-child {
            border-bottom: none;
        }
    }

    .pf-c-data-list__cell {
        // Align to center (when stretched wide)
        align-self: center;
        // Allow cells to be wrappable
        overflow-wrap: anywhere;

        // Comment is user@hostname
        &.comment {
            // Grow, shrink, and try to be around 12rem (or more or less)
            flex: 1 1 10rem;
        }

        &.fingerprint {
            // Grow more, shrink, and try to be around 20rem (or more or less)
            flex: 100 1 50%;
        }
    }

    // Handle empty state
    .no-keys {
        display: block;
        text-align: center;
        padding: var(--pf-global--spacer--lg);
    }
}

/* Use subgrid to properly align items, making the list act like a table  */
@supports (grid-template-columns: subgrid) {
    @media screen and (min-width: 512px) {
        #account-authorized-keys-list {
            display: grid;
            // This template will apply to the subgrids too
            grid-template-columns: minmax(8rem, auto) minmax(33%, 1fr) auto;

            /* Bring the grid through all the children */
            .pf-c-data-list__item,
            .pf-c-data-list__item-row:not(.no-keys),
            .pf-c-data-list__item-content {
                display: grid;
                grid-template-columns: subgrid;
            }

            /* Align children across all the grid */
            .pf-c-data-list__item,
            .pf-c-data-list__item-row {
                grid-column: 1 / -1;
            }

            /* Put the wrapper for the items on the first two grid cells (leaving the actions on the third) */
            .pf-c-data-list__item-content {
                grid-column: 1 / -2;
            }

            /* Place comment and fingerprint on their cells */
            .pf-c-data-list__cell {
                &.comment {
                    grid-column: 1;
                }

                &.fingerprint {
                    grid-column: 2;
                }
            }
        }
    }
}

#account-authorized-keys-list {
    border: none;
    margin-bottom: 0;
}

#account-authorized-keys-list > .list-group-item {
    display: flex;
    padding: 0.5rem 0.5rem 0.5rem 1rem;
    align-items: center;
}

.align-top {
    vertical-align: top;
}

.size-text-ct {
    display: inline;
    width: 8em;
    text-align: left;
    margin: 2px;
}

@media (min-width: 500px) {
    .modal-sm-ct {
        width: 32rem;
    }
}

.account-column-one {
    min-width: 270px;
    display: inline-block;
}

.expiration-modal .pf-c-form__group-control .pf-c-radio:first-child {
    padding-bottom: var(--pf-global--spacer--sm);
}

.help-block {
    white-space: pre-wrap;
}

.outline-question-circle-icon {
    margin-left: var(--pf-global--spacer--sm);
}