I have to create a customized and basic SVG Editor using HTML5/JS/jQuery/CSS.
Input for the Editor are two files x.svg and its associated x.css file.
The x.svg will be loaded in the HTML Page, with its styles from x.css applied. Then styles like stroke, width... will be manipulated using JS/jQuery, all fine so far.
My problem is that after the user make some changes to the style and want to save those changes permanently in the x.css file, I dont know how to do that, I can write the Attribute: Value pairs easily to a file, but the x.css files has selectors, braces and so on...the output of the program should be a prober x.css file, notice that the x.svg will remain the same. How can I handle this problem, an detailed idea with no code is sufficient, thanks.