Spaces:
Sleeping
Sleeping
| main { | |
| background-color: #F5F5F5; | |
| max-width: 100vw ; | |
| } | |
| /* Scrollbar Settings */ | |
| html * ::-webkit-scrollbar { | |
| width: 6px; | |
| background-color: transparent; | |
| } | |
| html * ::-webkit-scrollbar-thumb { | |
| border-radius: 10px; | |
| background-color: #d4d4d4; | |
| } | |
| html * ::-webkit-scrollbar-thumb:hover { | |
| background: #7d7d7d; /* darker when hovered */ | |
| } | |
| /* Item styling */ | |
| #col1-1 img{ | |
| width: 100%; | |
| height: 100%; | |
| object-fit: contain; | |
| padding: 30.32px 10px 5px 10px; /* top right bottom left */ | |
| } | |
| .html-container { | |
| padding: 0px ; | |
| } | |
| #col2 { | |
| display: flex; | |
| align-items: center; | |
| justify-content: center; | |
| border: 1px solid #e5e7eb; | |
| border-radius: 0.5rem; | |
| background-color: white; | |
| box-sizing: border-box; | |
| padding: max(0.64vw, 8px) max(0.96vw, 8px); | |
| } | |
| #col2 .img-wrapper { | |
| position: relative; | |
| display: flex; | |
| align-items: center; | |
| justify-content: center; | |
| } | |
| .bbox { | |
| position: absolute; | |
| cursor: pointer; | |
| background: none; | |
| border-style: solid; | |
| border-width: 3px; | |
| box-sizing: border-box; | |
| border-color: #FA7617; | |
| background-color: #fa761733; | |
| opacity: 0.5; | |
| transition: opacity 0.3s ease; | |
| } | |
| .bbox:hover { | |
| opacity: 1; | |
| background-color: transparent ; | |
| } | |
| .sub-bbox { | |
| border-color: #FBB73C; | |
| background-color: #FBB73C33; | |
| } | |
| .svg { | |
| width: 100%; | |
| height: 100%; | |
| pointer-events: none; /* allow hover to pass through*/ | |
| position: absolute; | |
| top: 0; | |
| left: 0; | |
| transition: opacity 0.3s ease; | |
| z-index: 1; | |
| } | |
| /* Clipping mask */ | |
| .svg .mask .outer { | |
| stroke-width: 2; | |
| stroke: white; | |
| fill: white; | |
| vector-effect: non-scaling-stroke; | |
| } | |
| .svg .mask .inner { | |
| fill: black; | |
| } | |
| /* Backgroound mask -> inverse of Clipping mask */ | |
| .svg .bg-mask .outer { | |
| fill: black; | |
| stroke: none; | |
| } | |
| .svg .bg-mask .inner { | |
| fill: white; | |
| stroke: none; | |
| } | |
| /* fill */ | |
| /* .svg .level0 { | |
| fill: #fa761733 !important; | |
| } */ | |
| /* stroke */ | |
| .svg .outer, .svg .inner { | |
| fill: transparent; | |
| stroke: #fa7617; | |
| stroke-dasharray: 10,5; /* dot length, gap length */ | |
| stroke-width: 2; | |
| vector-effect: non-scaling-stroke; /* keep stroke width after resizing */ | |
| } | |
| .svg .bg { | |
| fill: transparent; | |
| } | |
| .sub-svg .outer { | |
| cursor: pointer; | |
| pointer-events: visibleFill; | |
| } | |
| .sub-svg { | |
| z-index: 0; | |
| opacity: 0.7; | |
| } | |
| .sub-svg:has(.outer:hover) .level0 { | |
| fill: transparent ; | |
| } | |
| .sub-svg:has(.outer:hover) .outer, .sub-svg:has(.outer:hover) .inner { | |
| stroke-width: 3px; | |
| } | |
| .sub-svg:has(.outer:hover) .bg { | |
| fill: rgba(0, 0, 0, 0.5); | |
| } | |
| .img-wrapper:has(.sub-svg .outer:hover) .svg { | |
| opacity: 0; | |
| } | |
| .img-wrapper:has(.sub-svg .outer:hover) .sub-svg:has(.outer:hover) { | |
| opacity: 1; | |
| } | |
| .sub-svg .level0 { | |
| fill: #fbb83c1a ; | |
| } | |
| .sub-svg .outer, .sub-svg .inner { | |
| stroke: #FBB73C; | |
| stroke-dasharray: none; | |
| } | |
| .html-container:has(#col3), .html-container:has(#col3) .prose, #col3 { | |
| height: 100%; | |
| } | |
| #col3 { | |
| border: 1px solid #e5e7eb; | |
| border-radius: 0.5rem; | |
| background-color: white; | |
| box-sizing: border-box; | |
| padding: max(0.64vw, 8px) max(0.96vw, 8px); | |
| max-height: calc((max(12vw, 160px) + 1.1px) * 2 + 40px + 16px * 2); | |
| overflow-y: auto; | |
| } | |
| .reasoning-wrapper { | |
| display: flex; | |
| flex-direction: column; | |
| gap: 1rem; | |
| padding-top: 26px; | |
| overflow: visible; | |
| } | |
| .card { | |
| border: 1px solid #e5e7eb; | |
| border-radius: 0.5rem; | |
| padding: max(0.64vw, 8px) max(0.96vw, 12px); | |
| box-sizing: border-box; | |
| cursor: pointer; | |
| display: block; | |
| height: auto; | |
| position: relative; | |
| transition: box-shadow 0.3s ease; | |
| } | |
| .card .heading { | |
| font-size: max(1.05vw, 13px); | |
| font-weight: bold; | |
| padding-right: calc(max(1.4vw, 16px) + 2px); | |
| padding-bottom: 0.5em; | |
| } | |
| .card .highlight { | |
| background-color: #fa76174D; | |
| } | |
| /* hide the checkbox */ | |
| .card .card-toggle { | |
| position: absolute; | |
| right: max(0.96vw, 8px); | |
| top: max(0.64vw, 8px); | |
| width: max(1.4vw, 16px); | |
| height: max(1.4vw, 16px); | |
| border: 1px solid #e4e4e7; | |
| pointer-events: none; | |
| border-radius: 3px; | |
| margin: 0px; | |
| opacity: 0; | |
| transform: scale(0); | |
| transition: 0.3s ease; | |
| } | |
| .card input[type="checkbox"]:hover { | |
| opacity: 1; | |
| transform: scale(1); | |
| border-color: #f97316; | |
| box-shadow: 0 0 3px 1.5px #fa761733 | |
| } | |
| .card input[type="checkbox"]:checked { | |
| opacity: 1; | |
| transform: scale(1); | |
| background-color: #f97316; | |
| border-color: #f97316; | |
| border-color: #f97316; | |
| background-color: #f97316; | |
| background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='192' height='192' fill='%23FFFFFF' viewBox='0 0 256 256'%3E%3Crect width='256' height='256' fill='none'/%3E%3Cpolyline points='216 72.005 104 184 48 128.005' fill='none' stroke='%23FFFFFF' stroke-linecap='round' stroke-linejoin='round' stroke-width='32'/%3E%3C/svg%3E"); | |
| background-repeat: no-repeat; | |
| background-position: center; | |
| background-size: 70%; | |
| } | |
| /* highlight when checked */ | |
| .card:has(> .card-toggle:checked) { | |
| border-color: #f97316; | |
| box-shadow: 0 0 0 1px #f97316; | |
| } | |
| .card:hover { | |
| border-color: #f97316; | |
| box-shadow: 0 0 3px 1.5px #fa761733 | |
| } | |
| .card:hover:has(> .card-toggle:checked) { | |
| border-color: #f97316; | |
| box-shadow: 0 0 4px 1px #fa7617 | |
| } | |
| .card .content { | |
| display: flex; | |
| flex-direction: column; | |
| gap: 0.5em; | |
| } | |
| .sub-card { | |
| box-sizing: border-box; | |
| cursor: pointer; | |
| display: block; | |
| height: auto; | |
| display: grid; | |
| grid-template-areas: | |
| "a b" | |
| ". d"; /* the dot = empty cell */ | |
| grid-template-columns: auto 1fr; | |
| grid-template-rows: auto auto; | |
| column-gap: 1rem; | |
| align-items: start; | |
| } | |
| .sub-card .sub-card-toggle { | |
| grid-area: a; | |
| width: max(1vw, 14px); | |
| height: max(1vw, 14px); | |
| margin-top: 3px; | |
| margin-bottom: 0px; | |
| align-self: end; | |
| border: 1px solid #7d7d7d; | |
| border-radius: 3px; | |
| cursor: pointer; | |
| } | |
| .sub-card .sub-heading { | |
| grid-area: b; | |
| font-size: max(calc(1.05vw - 1px), 12.5px); | |
| font-weight: bold; | |
| } | |
| .sub-card .sub-content { | |
| grid-area: d; | |
| font-size: max(calc(1.05vw - 1.5px), 12px); | |
| color: #717171; | |
| } | |
| /* Interactive html iframe */ | |
| #row2 { | |
| display: flex; | |
| align-items: center; | |
| justify-content: center; | |
| padding: max(0.64vw, 8px); /* top/bottom, left/right */ | |
| border: 1px solid #e5e7eb; | |
| border-radius: 0.5rem; | |
| background-color: white; | |
| box-sizing: border-box; | |
| } | |
| #row2 .img-wrapper { | |
| display: flex; | |
| align-items: center; | |
| justify-content: center; | |
| width: 100%; | |
| height: 100%; | |
| padding: max(0.64vw, 8px) max(0.96vw, 8px); | |
| } | |
| #diagram-html { | |
| min-height: 300px; | |
| width: 100%; | |
| margin: 10px; | |
| margin-bottom: 5px; | |
| margin-top: 15px; | |
| } | |
| /* Text Block for Impression and Report */ | |
| .text-box { | |
| border: 1px solid #e5e7eb; | |
| border-radius: 0.5rem; | |
| background-color: white; | |
| box-sizing: border-box; | |
| padding: max(1.28vw, 16px) max(1.92vw, 16px); | |
| font-size: max(1.13vw, 14px); | |
| height: calc(8em + 7*0.5em + 2 * max(1.92vw, 16px) + 14px); /* 8 lines tall 8em + 8*0.5em */ | |
| overflow-y: auto; | |
| } | |
| .text-box .text-wrapper { | |
| margin-top: 14px; | |
| } | |
| #row4 .text-box { | |
| height: auto; | |
| } | |
| /* Label for each block */ | |
| .block-label { | |
| position: absolute; | |
| top: 0; | |
| left: 0; | |
| overflow: hidden; | |
| display: inline-flex; | |
| align-items: center; | |
| z-index: 2; | |
| border: 1px solid #e4e4e7; | |
| border-radius: 3px; | |
| background: white; | |
| padding: 4px 8px; | |
| pointer-events: none; | |
| color: #71717a; | |
| font-weight: 400; | |
| font-size: 12px; | |
| line-height: 1.4; | |
| } | |
| .block-label .img-icon { | |
| stroke: #939394; | |
| margin-right: 8px; | |
| width: 10.99px; | |
| height: 10.99px; | |
| } | |
| .block-label .html-icon { | |
| stroke: #939394; | |
| margin-right: 8px; | |
| width: auto; | |
| height: 10.99px; | |
| } | |
| .img-wrapper .img-icon { | |
| stroke: #939394; | |
| width: 20px; | |
| height: 20px; | |
| margin: auto; | |
| } | |
| .wrap:has(.error), .wrap:has(svg) { | |
| width: 100%; | |
| height: 100%; | |
| } | |
| /* Center for Gradio objects e.g. Error tag, loading icon */ | |
| /* .wrap { | |
| width: 100%; | |
| height: 100%; | |
| } */ | |
| /* wide screen*/ | |
| @media (min-width: 901px) { | |
| #row1 { | |
| display: grid; | |
| grid-template-columns: max(calc(12vw + 15px), 175px) calc((max(12vw, 160px) + 1.1px) * 2 + 40px + 16px * 2) 1fr; /* left fixed, right flexible */ | |
| align-items: stretch; | |
| gap: 16px; | |
| height: calc((max(12vw, 160px) + 1.1px) * 2 + 40px + 16px * 2); /* 2 upload (+border) + button + gap*/ | |
| } | |
| #col1 { display: flex; flex-direction: column; gap: 16px; } | |
| /* Shrink size of upload box */ | |
| #col1-1 .upload-container .wrap { | |
| min-height: 0px; | |
| font-size: max(0.9vw, 10px); | |
| padding-top: 30px; | |
| } | |
| #col1-1 .upload-container .wrap .icon-wrap { | |
| width: max(1.35vw, 10px); | |
| margin-bottom: max(0.3vw, 3px); | |
| } | |
| #col1 .image { height: max(12vw, 160px); } | |
| /* Set col2 to be a square and resize its containing image to take height/width */ | |
| #col2 { | |
| aspect-ratio: 1 / 1; | |
| height: 100%; | |
| } | |
| } | |
| /* Narrow screens: stack and fill width */ | |
| @media (max-width: 900px) { | |
| #row1 { flex-direction: column; align-items: stretch; } | |
| #col1 { max-width: none; } | |
| #col1 .image { max-height: 250px; } | |
| #col1-1 { flex-direction: row; } | |
| #col2 { height: 400px; } | |
| #col3 { min-height: 400px; height: 400px; max-height: 400px; } | |
| } |