D
D
doctorcat2016-06-29 20:37:55
css
doctorcat, 2016-06-29 20:37:55

I'm using the sass preprocessor. How to write in Cyrillic in the before pseudo-class of the content property?

There is a css block:

.onas .colorblock2:after {
    content: "О НАС";
    color: #3b794f;
    font-size: 24px;
    background-color: white;
    left: 45%;
    top: -26px;
    position: absolute;
    padding: 5px 10px;
  }

I'm trying to transfer it to SASS, but instead of the Cyrillic "ABOUT US". I see some abracadabra. How to be? Is there any method for displaying Cyrillic in content in sass? At the moment I just left this block in css. Because everything works flawlessly.

Answer the question

In order to leave comments, you need to log in

3 answer(s)
L
littleguga, 2016-06-29
@doctorcat

Why does SASS compile to IBM866 encoding?

A
Alexander Taratin, 2016-06-29
@Taraflex

Well, if you really want to use content, then you can
content: attr(data-title);
And in the html itself at the But element,
you are clearly trying to do something very strange. The only use case I can think of is disabling text selection, but this is solved with user-select: none;

Z
zooks, 2016-06-29
@zooks

Here you can see the code of different symbols for CSS:
www.utf8icons.com/subsets/cyrillic
In general, writing content in CSS is not recommended.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question