Let's say I have mark up:
<div data-generated="world!">Hello </div>
..with CSS:
div:after {
content: attr(data-generated);
}
This produces the text: Hello world! - FIDDLE
div:after {
content: attr(data-generated);
}
<div data-generated="world!">Hello </div>
BUT...
If I try to select / Copy the text - only the 'hello ' part is selectable.
Is there any way to select css generated text?
NB:
1) I have looked at the spec (here and here) regarding generated content and I haven't seen any reference to this issue.
The spec here and here seems to say that generated content should be selectable
Generated content should be searchable, selectable, and available to assistive technologies
2) If the answer to this question is 'no - it is not possible' - please link to a credible source which states this.