<commit_before>/**
 * BUIC: Select.
 */
.buic-select {
    display: table;
    width: 100%;
    margin-top: 4px;

    & > div {
        display: table-row;

        // Select
        & div:nth-child(odd) {
            display: table-cell;
            width: 100%;
        }

        // Buttons
        & div:nth-child(even) {
            display: table-cell;
            vertical-align: top;

            button {
                // btn-default + btn-xs
                @include button-variant($btn-default-color, $btn-default-bg, $btn-default-border);
                @include button-size($padding-xs-vertical, $padding-xs-vertical, $font-size-small, $line-height-small, $btn-border-radius-small);

                margin-left: 6px;
                margin-top: 4px;

                &:first-child {
                    margin-top: 3px;
                }

                &::before {
                    font-family: FontAwesome;
                    display: block;
                    width: $font-size-small * $line-height-small; // Make it quadratic (15px * 1.5)
                }

                &.select-all::before {
                    content: "\f00c";
                }

                &.select-none::before {
                    content: "\f00d";
                }
            }
        }
    }

    // Overwrite select2 that sets inline style width that is too wide.
    .select2-search__field {
        width: 100% !important;
    }
}
<commit_msg>Fix stretching selects. Fixes #4570<commit_after>/**
 * BUIC: Select.
 */
.buic-select {
    display: table;
    width: 100%;
    margin-top: 4px;

    & > div {
        display: table-row;

        // Select
        & div:nth-child(odd) {
            display: table-cell;
            width: 100%;
        }

        // Buttons
        & div:nth-child(even) {
            display: table-cell;
            vertical-align: top;

            button {
                // btn-default + btn-xs
                @include button-variant($btn-default-color, $btn-default-bg, $btn-default-border);
                @include button-size($padding-xs-vertical, $padding-xs-vertical, $font-size-small, $line-height-small, $btn-border-radius-small);

                margin-left: 6px;
                margin-top: 4px;

                &:first-child {
                    margin-top: 3px;
                }

                &::before {
                    font-family: FontAwesome;
                    display: block;
                    width: $font-size-small * $line-height-small; // Make it quadratic (15px * 1.5)
                }

                &.select-all::before {
                    content: "\f00c";
                }

                &.select-none::before {
                    content: "\f00d";
                }
            }
        }
    }

    // Overwrite select2 that sets inline style width that is too wide.
    .select2-search__field {
        width: 100% !important;
    }

    // Allow wordwrap (and trimming). Fixes https://github.com/bolt/bolt/issues/4570
    .select2-selection--single .select2-selection__rendered {
        word-break: break-all;
        height: 2em;
        white-space: normal;
    }

}

{'fraction_non_alphanumeric': 0.12452830188679245, 'fraction_numerical': 0.017924528301886792, 'mean_word_length': 1.1998616874135546, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 5, 'https://': 1, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5191435', 'n_tokens_mistral': 993, 'n_tokens_neox': 885, 'n_words': 176}