This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| function cleanLayerStyless(array) { | |
| var layers = [] | |
| array.forEach(function(layer) { | |
| if (layer.class() == 'MSShapeGroup') layers.push(layer) | |
| }) | |
| for (var i = 0; i < layers.length; i++) { | |
| layers.forEach(function(layer, index) { | |
| var fills = layer.style().fills() | |
| fills.forEach(function(fill, fillIndex) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| function createDialogWindow(context) { | |
| // Setup the window | |
| var alert = COSAlertWindow.new() | |
| alert.setMessageText("Example modal") | |
| alert.addButtonWithTitle("Run") | |
| alert.addButtonWithTitle("Cancel") | |
| // Create initial view panel | |
| var width = 425 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| example.sketchPlugin | |
| └── Contents | |
| ├── Resources | |
| └── Sketch | |
| ├── manifest.json | |
| └── yourFunction.js |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // Future versions of Hyper may add additional config options, | |
| // which will not automatically be merged into this file. | |
| // See https://hyper.is#cfg for all currently supported options. | |
| module.exports = { | |
| config: { | |
| // Choose either "stable" for receiving highly polished, | |
| // or "canary" for less polished but more frequent updates | |
| updateChannel: 'stable', |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var selection = context.selection | |
| var shapeGroups = [] | |
| function searchInLayer(layer) { | |
| switch (layer.class())) { | |
| case MSPage: | |
| case MSLayerGroup: | |
| case MSArtboardGroup: | |
| let sublayers = layer.layers() | |
| for (let i = 0; i < sublayers.count(); i++) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| secondsToHourMinuteSecond(totalSeconds) { | |
| let hour = Math.floor(totalSeconds / 3600); | |
| let minute = Math.floor(totalSeconds % 3600 / 60); | |
| let seconds = Math.floor(totalSeconds % 3600 % 60); | |
| return `${('0' + hour).slice(-2)}:${('0' + minute).slice(-2)}:${('0' + seconds).slice(-2)}` | |
| } | |
| /* | |
| returns total seconds to hh:mm:ss value. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| root = true | |
| [*.py] | |
| indent_style = tab | |
| indent_size = 4 | |
| insert_final_newline = true | |
| trim_trailing_whitespace = true | |
| end_of_line = lf | |
| charset = utf-8 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| # mime = meme | |
| function cc_mime_types($memes) { | |
| $memes['svg'] = 'image/svg+xml'; | |
| return $memes; | |
| } | |
| add_filter('upload_mimes', 'cc_mime_types'); | |
| function fix_svg() { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| version: '2' | |
| services: | |
| wordpress: | |
| depends_on: | |
| - db | |
| image: wordpress:4.7.1 | |
| restart: always | |
| volumes: | |
| - ./wp-content:/var/www/html/wp-content | |
| environment: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?xml version="1.0" encoding="UTF-8"?> | |
| <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> | |
| <plist version="1.0"> | |
| <dict> | |
| <key>ANSIBlackColor</key> | |
| <data> | |
| YnBsaXN0MDDUAQIDBAUGKyxYJHZlcnNpb25YJG9iamVjdHNZJGFyY2hpdmVyVCR0b3AS | |
| AAGGoKcHCBMZHSQoVSRudWxs1QkKCwwNDg8QERJcTlNDb21wb25lbnRzVU5TUkdCXE5T | |
| Q29sb3JTcGFjZV8QEk5TQ3VzdG9tQ29sb3JTcGFjZVYkY2xhc3NPECgwLjIwNzg0MzEz | |
| NzMgMC4yNDcwNTg4MjM1IDAuMjg2Mjc0NTA5OCAxTxAnMC4xNTc1NDY3NDM4IDAuMTg4 |
OlderNewer