/*
 * Copyright (C) 2017 Apple Inc. All rights reserved.
 *
 * Redistribution and use in source and binary forms, with or without
 * modification, are permitted provided that the following conditions
 * are met:
 * 1. Redistributions of source code must retain the above copyright
 *    notice, this list of conditions and the following disclaimer.
 * 2. Redistributions in binary form must reproduce the above copyright
 *    notice, this list of conditions and the following disclaimer in the
 *    documentation and/or other materials provided with the distribution.
 *
 * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS''
 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
 * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
 * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS
 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
 * THE POSSIBILITY OF SUCH DAMAGE.
 */

.web-socket.content-view > .data-grid {
    height: 100%;
}

.web-socket.content-view > .data-grid table.data {
    height: auto;
    background-image: none;
}

.web-socket.content-view > .data-grid td.data-column,
.web-socket.content-view .data-grid td.data-column > div {
    height: auto;
    white-space: pre-wrap;
    overflow-wrap: break-word;
}

body[dir=ltr] .web-socket.content-view > .data-grid .data-column > div {
    padding-left: 18px;
}

body[dir=rtl] .web-socket.content-view > .data-grid .data-column > div {
    padding-right: 18px;
}

.web-socket.content-view .icon {
    position: absolute;
    margin-top: -1px;
}

body[dir=ltr] .web-socket.content-view .icon {
    left: 4px;
    margin-right: 2px;
}

body[dir=rtl] .web-socket.content-view .icon {
    right: 4px;
    margin-left: 2px;
}

.web-socket.content-view .data-grid.variable-height-rows table.data tr:nth-child(odd) {
    background-color: unset;
}

.web-socket.content-view .data-grid table.data tr.revealed {
    border-bottom: 0.5px solid hsla(0, 0%, 0%, 0.1);
}

.web-socket.content-view .data-grid.variable-height-rows table.data tr.outgoing {
    background-color: hsl(80, 85%, 92%);
    color: hsl(120, 100%, 16%);
}

.web-socket.content-view .data-grid.variable-height-rows table.data tr.non-text-frame {
    background-color: hsl(50, 100%, 90%);
    color: hsl(3, 96%, 27%);
}
