discourse/app/assets/stylesheets/common/base/emoji.scss

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

290 lines
5.2 KiB
SCSS
Raw Normal View History

img.emoji {
width: 20px;
height: 20px;
vertical-align: middle;
}
img.emoji.only-emoji {
width: 32px;
height: 32px;
margin: 0.5em 0;
}
a,
.md-table,
.poll {
img.emoji.only-emoji {
width: 20px;
height: 20px;
margin: 0;
}
}
small img.emoji,
sub img.emoji,
sup img.emoji {
height: 1.1em;
width: 1.1em;
}
2017-07-11 23:51:53 +08:00
.emoji-picker {
background-clip: padding-box;
z-index: z("modal", "content");
position: fixed;
display: none;
2017-07-11 23:51:53 +08:00
flex-direction: row;
height: 320px;
color: var(--primary);
background-color: var(--secondary);
border: 1px solid var(--primary-low);
img.emoji {
// custom emojis might import images of various sizes
// we don't want the picker to be difformed
width: 20px !important;
height: 20px !important;
}
}
2017-07-11 23:51:53 +08:00
.emoji-picker .categories-column {
display: flex;
flex-direction: column;
flex: 1 0 0px;
2017-07-11 23:51:53 +08:00
align-items: center;
justify-content: space-between;
border-right: 1px solid var(--primary-low);
2017-07-11 23:51:53 +08:00
min-width: 36px;
overflow-y: auto;
padding: 0.5em;
}
2017-07-11 23:51:53 +08:00
.emoji-picker .category-icon {
display: block;
2017-07-11 23:51:53 +08:00
margin: 4px auto;
-webkit-filter: grayscale(100%);
filter: grayscale(100%);
button.emoji {
margin: 0;
padding: 0;
}
}
.emoji-picker .category-icon.current,
.emoji-picker .category-icon:hover {
2017-07-11 23:51:53 +08:00
-webkit-filter: grayscale(0%);
filter: grayscale(0%);
}
2017-07-11 23:51:53 +08:00
.emoji-picker .main-column {
display: flex;
flex-direction: column;
flex: 20;
}
2017-07-11 23:51:53 +08:00
.emoji-picker .list {
overflow-y: scroll;
-webkit-overflow-scrolling: touch;
padding: 0;
flex: 1 0 0px;
2017-07-11 23:51:53 +08:00
flex-direction: column;
}
2017-07-11 23:51:53 +08:00
.emoji-picker .section-header {
padding: 8px;
margin-top: 2px;
margin-bottom: 0px;
padding-bottom: 0px;
2017-07-11 23:51:53 +08:00
justify-content: space-between;
display: flex;
align-items: center;
font-weight: bold;
}
2017-07-11 23:51:53 +08:00
.emoji-picker .section-header .title {
color: var(--primary);
}
.emoji-picker .section-header .clear-recent .fa {
2017-07-11 23:51:53 +08:00
margin: 0;
2017-07-21 20:19:04 +08:00
padding: 0;
color: var(--primary-medium);
2017-07-21 20:19:04 +08:00
&:hover {
color: var(--primary-high);
2017-07-21 20:19:04 +08:00
}
}
2017-07-20 02:29:39 +08:00
.emoji-picker .section-group {
2017-07-11 23:51:53 +08:00
flex-wrap: wrap;
display: flex;
align-items: center;
justify-content: flex-start;
padding: 4px;
}
2017-07-11 23:51:53 +08:00
.emoji-picker .footer {
align-items: center;
2017-07-11 23:51:53 +08:00
display: flex;
justify-content: space-between;
border-top: 1px solid var(--primary-low);
}
2017-07-11 23:51:53 +08:00
.emoji-picker .info {
@include ellipsis;
2017-07-11 23:51:53 +08:00
padding-left: 8px;
font-weight: 700;
max-width: 125px;
}
2017-07-11 23:51:53 +08:00
.emoji-picker .diversity-picker {
display: flex;
2017-07-11 23:51:53 +08:00
justify-content: flex-end;
padding: 8px;
}
2017-07-11 23:51:53 +08:00
.emoji-picker .diversity-picker .diversity-scale {
width: 20px;
height: 20px;
margin-left: 5px;
border: 0;
border-radius: 3px;
display: flex;
align-items: center;
justify-content: center;
2017-06-29 06:27:16 +08:00
cursor: pointer;
}
.emoji-picker .diversity-picker .diversity-scale.default {
background: #ffcc4d;
}
.emoji-picker .diversity-picker .diversity-scale.light {
background: #f7dece;
}
.emoji-picker .diversity-picker .diversity-scale.medium-light {
background: #f3d2a2;
}
.emoji-picker .diversity-picker .diversity-scale.medium {
background: #d5ab88;
}
.emoji-picker .diversity-picker .diversity-scale.medium-dark {
background: #af7e57;
}
.emoji-picker .diversity-picker .diversity-scale.dark {
background: #7c533e;
}
2017-07-11 23:51:53 +08:00
Upgrade to FontAwesome 5 (take two) (#6673) * Add missing icons to set * Revert FA5 revert This reverts commit 42572ff * use new SVG syntax in locales * Noscript page changes (remove login button, center "powered by" footer text) * Cast wider net for SVG icons in settings - include any _icon setting for SVG registry (offers better support for plugin settings) - let themes store multiple pipe-delimited icons in a setting - also replaces broken onebox image icon with SVG reference in cooked post processor * interpolate icons in locales * Fix composer whisper icon alignment * Add support for stacked icons * SECURITY: enforce hostname to match discourse hostname This ensures that the hostname rails uses for various helpers always matches the Discourse hostname * load SVG sprite with pre-initializers * FIX: enable caching on SVG sprites * PERF: use JSONP for SVG sprites so they are served from CDN This avoids needing to deal with CORS for loading of the SVG Note, added the svg- prefix to the filename so we can quickly tell in dev tools what the file is * Add missing SVG sprite JSONP script to CSP * Upgrade to FA 5.5.0 * Add support for all FA4.7 icons - adds complete frontend and backend for renamed FA4.7 icons - improves performance of SvgSprite.bundle and SvgSprite.all_icons * Fix group avatar flair preview - adds an endpoint at /svg-sprites/search/:keyword - adds frontend ajax call that pulls icon in avatar flair preview even when it is not in subset * Remove FA 4.7 font files
2018-11-27 05:49:57 +08:00
.emoji-picker .diversity-picker .diversity-scale.selected .d-icon {
2017-07-11 23:51:53 +08:00
display: block;
}
Upgrade to FontAwesome 5 (take two) (#6673) * Add missing icons to set * Revert FA5 revert This reverts commit 42572ff * use new SVG syntax in locales * Noscript page changes (remove login button, center "powered by" footer text) * Cast wider net for SVG icons in settings - include any _icon setting for SVG registry (offers better support for plugin settings) - let themes store multiple pipe-delimited icons in a setting - also replaces broken onebox image icon with SVG reference in cooked post processor * interpolate icons in locales * Fix composer whisper icon alignment * Add support for stacked icons * SECURITY: enforce hostname to match discourse hostname This ensures that the hostname rails uses for various helpers always matches the Discourse hostname * load SVG sprite with pre-initializers * FIX: enable caching on SVG sprites * PERF: use JSONP for SVG sprites so they are served from CDN This avoids needing to deal with CORS for loading of the SVG Note, added the svg- prefix to the filename so we can quickly tell in dev tools what the file is * Add missing SVG sprite JSONP script to CSP * Upgrade to FA 5.5.0 * Add support for all FA4.7 icons - adds complete frontend and backend for renamed FA4.7 icons - improves performance of SvgSprite.bundle and SvgSprite.all_icons * Fix group avatar flair preview - adds an endpoint at /svg-sprites/search/:keyword - adds frontend ajax call that pulls icon in avatar flair preview even when it is not in subset * Remove FA 4.7 font files
2018-11-27 05:49:57 +08:00
.emoji-picker .diversity-picker .d-icon {
2017-07-11 23:51:53 +08:00
display: none;
}
.emoji-picker .diversity-picker .d-icon {
color: #fff;
2018-01-13 06:27:38 +08:00
font-size: $font-0;
Upgrade to FontAwesome 5 (take two) (#6673) * Add missing icons to set * Revert FA5 revert This reverts commit 42572ff * use new SVG syntax in locales * Noscript page changes (remove login button, center "powered by" footer text) * Cast wider net for SVG icons in settings - include any _icon setting for SVG registry (offers better support for plugin settings) - let themes store multiple pipe-delimited icons in a setting - also replaces broken onebox image icon with SVG reference in cooked post processor * interpolate icons in locales * Fix composer whisper icon alignment * Add support for stacked icons * SECURITY: enforce hostname to match discourse hostname This ensures that the hostname rails uses for various helpers always matches the Discourse hostname * load SVG sprite with pre-initializers * FIX: enable caching on SVG sprites * PERF: use JSONP for SVG sprites so they are served from CDN This avoids needing to deal with CORS for loading of the SVG Note, added the svg- prefix to the filename so we can quickly tell in dev tools what the file is * Add missing SVG sprite JSONP script to CSP * Upgrade to FA 5.5.0 * Add support for all FA4.7 icons - adds complete frontend and backend for renamed FA4.7 icons - improves performance of SvgSprite.bundle and SvgSprite.all_icons * Fix group avatar flair preview - adds an endpoint at /svg-sprites/search/:keyword - adds frontend ajax call that pulls icon in avatar flair preview even when it is not in subset * Remove FA 4.7 font files
2018-11-27 05:49:57 +08:00
filter: drop-shadow(0.5px 1.5px 0 rgba(0, 0, 0, 0.3));
}
2017-07-11 23:51:53 +08:00
.emoji-picker button.emoji {
background: transparent;
background-position: center;
background-repeat: no-repeat;
border-radius: 0;
background-size: 20px 20px;
-moz-box-sizing: content-box;
box-sizing: content-box;
2017-07-11 23:51:53 +08:00
height: 20px;
border: 0;
vertical-align: top;
width: 20px;
outline: none;
padding: 3px;
margin: 2px;
}
.emoji-picker .section-group button.emoji:hover,
.emoji-picker .results button.emoji:hover {
display: inline-block;
vertical-align: top;
border-radius: 2px;
background-color: var(--tertiary-low);
2017-07-11 23:51:53 +08:00
}
.emoji-picker-modal.fadeIn {
z-index: z("modal", "overlay");
2017-07-11 23:51:53 +08:00
position: fixed;
left: 0;
top: 0;
width: 100%;
height: 100%;
opacity: 0.8;
2017-07-11 23:51:53 +08:00
background-color: black;
}
.emoji-picker .filter {
2017-07-20 02:20:52 +08:00
background-color: none;
border-bottom: 1px solid var(--primary-low);
2017-07-11 23:51:53 +08:00
padding: 5px;
display: flex;
position: relative;
2017-07-20 02:20:52 +08:00
align-items: center;
input[type="text"] {
width: auto !important;
}
2017-07-20 02:20:52 +08:00
}
.emoji-picker .filter .d-icon-search {
color: var(--primary-medium);
2018-01-13 06:27:38 +08:00
font-size: $font-up-1;
2017-07-20 02:20:52 +08:00
margin-left: 5px;
margin-right: 5px;
2017-07-11 23:51:53 +08:00
}
.emoji-picker .filter input {
height: 24px;
margin: 0;
flex: 1 0 0px;
2017-07-20 02:20:52 +08:00
border: none;
box-shadow: none;
2017-07-11 23:51:53 +08:00
padding-right: 24px;
2017-07-20 02:20:52 +08:00
outline: none;
color: var(--primary);
background: var(--secondary);
2017-07-20 02:20:52 +08:00
&:focus {
border: none;
box-shadow: none;
}
2017-07-11 23:51:53 +08:00
}
2017-07-19 20:28:08 +08:00
.emoji-picker .filter input::-ms-clear {
display: none;
}
2017-07-11 23:51:53 +08:00
.emoji-picker .results {
display: none;
flex-wrap: wrap;
align-items: center;
justify-content: flex-start;
padding: 4px;
flex: 1 0 0px;
2017-07-11 23:51:53 +08:00
}
.emoji-picker .filter .clear-filter {
position: absolute;
2017-07-20 02:20:52 +08:00
right: 5px;
2017-07-11 23:51:53 +08:00
top: 12px;
border: 0;
background: none;
color: var(--primary-high);
2017-07-11 23:51:53 +08:00
outline: none;
display: none;
&:hover {
color: var(--primary);
2017-07-11 23:51:53 +08:00
}
}