Skip to content
View in the app

A better way to browse. Learn more.

Web Designer Forum

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

CreativeSheep

Privileged
  • Joined

  • Last visited

  1. I'm trying to see the results of this code in CodePen with Paper.js using the following CDN(https://cdn.jsdelivr.net/paperjs/0.10.2/paper-full.min.js) but I see nothing within CodePen ? var path = new Path(); path.strokeColor = '#567e37'; path.strokeWidth = 5; var firstPoint = new Point(0, 550); path.add(firstPoint); var throughPoint = new Point(75, 400); var toPoint = new Point(100, 250); path.arcTo(throughPoint, toPoint);
  2. Look as if I'm going to have to manually edit the SVG file None of these processors can do what manually I can do.
  3. Anyone familiar as to what options might be able to drastically reduce the XML data with SVGO because that is my biggest concern as there is too much XML data.
  4. Processing the folder worked. If I should have multiple SVG and I want to do specific settings for individual SVG I suppose at this point I can't.
  5. No change when not appending a number to the original file name; the file size remains the same and so it appears the contexts of the file as well. Removing the flags causes a Unknown Argument for: convertShapeToPath and removing convertShapeToPath causes an unknown argument; for the file name in the path which is as you know C:\1
  6. I got SVGO which as you all probably know is a Node.js module working I ran the following command but svgo didn't generate a second version of the original file but the process was complete ? svgo -i INPUT C:\1\woolpartmorph.svg convertShapeToPath -o C:\1\woolpartmorph2.svg
  7. rbrsmith - You add a class to all <path> tags, you can't tell me that, that is not possible, maybe you will !
  8. The site mentioned in post #11 the person wants identical to that what I want to do, and it appears possible. rbrsmith, based on what you are telling me and I understand that the computer needs a consistent path to follow to make it work but the site I mentioned in post #11 appears to have solved that problem ? Regardless if we understand each other, there must be a method to which I can parse a SVG file and for each <path> tag add a class name ?
  9. SVG files have <path> tags that is where you can insert class names. It sounds as if you're saying it can't be done, but it can be done in your paragraph following ?
  10. First off, before I dive into any other question asked, is; shouldn't the command grunt in the node command prompt not cause an error ? I want to feed a SVG file and have all paths in the SVG file be given custom class names automatically, eliminating the need for me to do it manually; that is where I hope my assumption was correct where grunt come in to help ?
  11. This is a supposedly a complete grunt task as mentioned here and so this is wrong ?
  12. Here is the code ? replace: { // ID cleanup: performs a manual ID cleanup as Illustrator exports a mess illustrator: { src: ['assets/svg/optimised/*.svg'], overwrite: true, replacements: [{ // Remove escaped underscore character from: '_x5F_', to: '_' }, { // Replace class names with proper classes //class_x3D__x22_tank-option_x22__2_ from: /id\=\"class_x3D__x22_(.+?)_x22_(.*?)\"/gi, to: function(matchedWord, index, fullText, regexMatches) { return 'class="'+ regexMatches[0].toLowerCase()+'"'; } }, { // Lowercase all ids from: /id\=\"(.+?)\"/gi, to: function(matchedWord, index, fullText, regexMatches) { return 'id="'+ regexMatches[0].toLowerCase()+'"'; } }, { // Lowercase all id references to match the previous replace rule from: /url\(\#(.+?)\)/gi, to: function(matchedWord, index, fullText, regexMatches) { return 'url(#'+ regexMatches[0].toLowerCase() +')'; } }, { // Lowercase all id href to match the previous replace rule from: /href\=\"\#(.+?)\"/gi, to: function(matchedWord, index, fullText, regexMatches) { return 'href="#'+ regexMatches[0].toLowerCase() +'"'; } }, { // Remove all font references as we will use CSS for this from: /font\-family\=\"(.+?)\"/gi, to: function(matchedWord, index, fullText, regexMatches) { return ''; } }] } }
  13. jak - Before I proceed any further, placing the grunt task in a file called gruntfile.js, is correct ? I have the task command to trigger the task, as well, why am I getting this error when running the command; grunt ?
  14. That is the error I get; how do I create a default task ?
  15. I managed, to get Grunt Installed. I have a gruntfile.js, within the gruntfile.js I have a grunt file task, how do I run a grunt task within obviously node command prompt ?

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.