GithubHelp home page GithubHelp logo

Comments (4)

w8tcha avatar w8tcha commented on September 24, 2024

Can you describe the steps to reproduce the problem and also post you editor config?

from ckeditor-textselection-plugin.

dm0 avatar dm0 commented on September 24, 2024

I believe editor config is not important.
Steps to reproduce:
Add following code to the top of page source on demo page (http://w8tcha.github.io/CKEditor-TextSelection-Plugin/demoCodeMirror.html):

<style type="text/css">
.someClass {
  width: 100%;
}
</style>

Leave text cursor inside style tag (i.e. put it after semicolon).
Switch to wysiwyg mode.

Error reported by browser is not always accurate, but failing call is:
decodeURIComponent(startNode.$.nodeValue)

Reason - nodeValue of style tag doesn't contain valid URL-enoded data (it has percent sign followed by semicolon)

from ckeditor-textselection-plugin.

dm0 avatar dm0 commented on September 24, 2024

I have a fix for this problem in my fork, but it is not well-tested yet, so i'm not sure if everything is ok.

fork is here: https://github.com/dm0/CKEditor-TextSelection-Plugin

Also in my fix I attempted to resolve problem of empty lines addition to source code of style and script tags.

from ckeditor-textselection-plugin.

w8tcha avatar w8tcha commented on September 24, 2024

Thanks now i was able to reproduce the issue, but you fix attempt doesn't seem to work.

I replaced decodeURIComponent with unescape and now it seem to work

from ckeditor-textselection-plugin.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.