{"version":3,"sources":["jsdelivr-header.js","/npm/generator-pattern-lab-patterns@0.0.2/app/index.js"],"names":[],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA,ACNA,aACA,IAAI,WAAa,QAAQ,oBACrB,MAAQ,QAAQ,SAChB,MAAQ,QAAQ,SAChB,GAAK,QAAQ,MACb,EAAI,QAAQ,UAEhB,OAAO,QAAU,WAAW,KAAK,OAAO,CACxC,aAAc,WACV,KAAK,IAAM,QAAQ,kBACrB,EAEA,UAAW,WACR,IAAI,EAAO,KAAK,QAGjB,KAAK,IAAI,MACP,4CAIF,IAUI,EAAU,CAAC,CACb,KAAM,OACN,KAAM,oBACN,QAAS,wCACT,QAdmB,EAAE,OAAO,GAAG,YAAY,KAAK,iBAAiB,SAAS,GAE1E,OAAK,EAAM,MAAM,MAKnB,MAWA,KAAK,OAAO,EAAS,SAAU,GAC7B,KAAK,MAAQ,EAEb,GACF,EAAE,KAAK,MAET,EACA,QAAS,CACP,IAAK,WACH,KAAK,GAAG,KACN,KAAK,aAAa,KAAK,MAAM,mBAC7B,KAAK,kBAET","file":"/npm/generator-pattern-lab-patterns@0.0.2/app/index.js","sourceRoot":"","sourcesContent":["/**\n * Minified by jsDelivr using Terser v5.39.0.\n * Original file: /npm/generator-pattern-lab-patterns@0.0.2/app/index.js\n *\n * Do NOT use SRI with dynamically generated files! More information: https://www.jsdelivr.com/using-sri-with-dynamic-files\n */\n","'use strict';\nvar generators = require('yeoman-generator');\nvar chalk = require('chalk');\nvar yosay = require('yosay');\nvar fs = require('fs');\nvar _ = require('lodash');\n\nmodule.exports = generators.Base.extend({\ninitializing: function () {\n    this.pkg = require('../package.json');\n  },\n\n  prompting: function () {\n     var done = this.async();\n\n    // Have Yeoman greet the user.\n    this.log(yosay(\n      'Hi! Let\\'s get you some patterns to use!'\n    ));\n    \n    // Creates an array of directories inside \"app/templates/\" - our pattern options\n    var patternOptions = _.filter(fs.readdirSync(this.templatePath()), function(value){\n      // filtering out directories that start with `.` - like `.DS_Store`\n      if (!value.match(/^\\./)) {\n        return true;\n      } else {\n        return false;\n      }\n    });\n    \n    // Setting up our questions\n    var prompts = [{\n      type: 'list',\n      name: 'patternCollection',\n      message: 'Which set of patterns would you like?',\n      choices: patternOptions\n    }];\n    \n    // Asking our questions\n    this.prompt(prompts, function (props) {\n      this.props = props;\n      // To access props later use this.props.someOption;\n      done();\n    }.bind(this));\n    \n  },\n  writing: {\n    app: function () {\n      this.fs.copy(\n        this.templatePath(this.props.patternCollection),\n        this.destinationPath()\n      );\n    }\n  }\n  // install: function () {\n  //   this.installDependencies();\n  // }\n});"]}