Skip to content

Commit

Permalink
Changes colors array to NSMutableArray
Browse files Browse the repository at this point in the history
Fixes #42
  • Loading branch information
lalomts committed Feb 21, 2019
1 parent 10d857e commit 8f5e861
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 5 deletions.
9 changes: 7 additions & 2 deletions Prism.sketchplugin/Contents/Sketch/build/Palette.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions Prism.sketchplugin/Contents/Sketch/manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,10 @@
"description": "Creates a beautiful artboard with all the colors in your 'Document Colors' with its respective color label in a variety of formats.",
"author": "Lalo Mrtnz & Adrián Rubio",
"homepage": "https://github.com/ment-mx/Prism",
"version": "1.0.7",
"version": "1.0.8",
"identifier": "com.ment.sketch.prism",
"appcast": "https://raw.githubusercontent.com/ment-mx/Prism/master/appcast.xml",
"compatibleVersion": "41",
"compatibleVersion": "53",
"bundleVersion": "2.0",
"commands" : [
{
Expand Down
6 changes: 5 additions & 1 deletion Prism.sketchplugin/Contents/Sketch/src/Palette.coffee
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,11 @@ class Palette extends Base
@artboard = layer

if @context.document
@colors = @context.document.documentData().assets().colors()
documentColorAssets = @context.document.documentData().assets().colorAssets().objectEnumerator()
colorsArray = NSMutableArray.alloc().init()
while color = documentColorAssets.nextObject()
colorsArray.addObject(color.color())
@colors = colorsArray

regenerate: ->
array = @getColorsDictionaries().map (colorDictionary) ->
Expand Down

0 comments on commit 8f5e861

Please sign in to comment.