├── res ├── icon.png └── snapshot.png ├── chrome-sketchtab.jpg ├── manifest.json ├── sandbox.html ├── LICENSE ├── README.md ├── styles.css ├── index.html ├── script.js └── codemirror ├── mode ├── htmlmixed │ └── htmlmixed.js ├── xml │ └── xml.js ├── javascript │ └── javascript.js └── css │ └── css.js └── codemirror.css /res/icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/spite/chrome-sketchtab/HEAD/res/icon.png -------------------------------------------------------------------------------- /res/snapshot.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/spite/chrome-sketchtab/HEAD/res/snapshot.png -------------------------------------------------------------------------------- /chrome-sketchtab.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/spite/chrome-sketchtab/HEAD/chrome-sketchtab.jpg -------------------------------------------------------------------------------- /manifest.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "Sketchtab", 3 | "short_name": "Sketchtab", 4 | "description": "New tab page with code editor", 5 | "version": "0.7", 6 | "incognito": "split", 7 | "chrome_url_overrides": { 8 | "newtab": "index.html" 9 | }, 10 | "web_accessible_resources": [ 11 | "index.html" 12 | ], 13 | "sandbox": { 14 | "pages": ["sandbox.html"] 15 | }, 16 | "manifest_version": 2, 17 | "content_security_policy": "script-src 'self'; object-src 'self'" 18 | } -------------------------------------------------------------------------------- /sandbox.html: -------------------------------------------------------------------------------- 1 | 2 | 3 |
4 | 5 | 6 | 29 | 30 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | The MIT License (MIT) 2 | 3 | Copyright (c) 2016 Jaume Sanchez 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Chrome SketchTab 2 | ##### New tab page with code editor 3 | 4 | A New Tab for Google Chrome with a code editor 5 | 6 |  7 | 8 | ### How to install #### 9 | 10 | [](https://chrome.google.com/webstore/detail/sketchtab/ioonoapnncbgnhjfjipkfbkpkogmknlm) 11 | 12 | [Install the extension from the Chrome Store](https://chrome.google.com/webstore/detail/sketchtab/ioonoapnncbgnhjfjipkfbkpkogmknlm) 13 | 14 | #### Features #### 15 | 16 | - HTML editor 17 | - CSS editor 18 | - JavaScript editor 19 | - Live output 20 | - Console output 21 | - Keeps state on LocalStorage 22 | 23 | # The MIT License (MIT) 24 | **Copyright © 2016 Jaume Sanchez Elias** 25 | 26 | * * * 27 | 28 | Permission is hereby granted, free of charge, to any person obtaining a copy of 29 | this software and associated documentation files (the “Software”), to deal in 30 | the Software without restriction, including without limitation the rights to 31 | use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of 32 | the Software, and to permit persons to whom the Software is furnished to do so, 33 | subject to the following conditions: 34 | 35 | The above copyright notice and this permission notice shall be included in all 36 | copies or substantial portions of the Software. 37 | 38 | THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 39 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 40 | FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 41 | COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 42 | IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 43 | CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 44 | -------------------------------------------------------------------------------- /styles.css: -------------------------------------------------------------------------------- 1 | *{ margin: 0; padding: 0; box-sizing: border-box; font-family: "courier new"; font-size: 12px;} 2 | body{ position: absolute; height: 100%; width: 100%; overflow:hidden;} 3 | h3{ font-size: 14px; } 4 | .block{ position: absolute; left: 0; top: 25px; right: 0; bottom:0; width: 100%; height: calc(100%-30px); outline:none; border: none; } 5 | textarea.block{ padding: 10px; resize: none; border-top: 1px solid #ddd; border-bottom: 1px solid #fff; border-left: 1px solid #ddd; border-right: 1px solid #fff; } 6 | .block:focus{ background-color: #e5edff; } 7 | #console-output{ list-style-type: none; top: 30px; overflow: auto; } 8 | #console-output li{ padding: 0px 10px;} 9 | #console-output li:nth-child(odd) { background-color: #eee;} 10 | #console-output span{ margin-right: .4em;} 11 | #html-output{ } 12 | button{ padding: 10px;} 13 | a{ color: inherit;} 14 | a:hover{ color: #ff00ff;} 15 | 16 | header{ position: absolute; left: 0; top: 0; right: 0; height: 30px; display: flex; } 17 | header * { padding: 10px;} 18 | #main{ position: absolute; left: 0; top: 30px; right: 0; bottom: 0; width: 100%; height: calc(100%-30px); } 19 | .toolbar{ display: flex; width: 100%; background-color: #eee; } 20 | .toolbar *{ padding: 5px 10px; } 21 | 22 | .columns .container{ width: 20%; height: 100%; float:left; position: relative; } 23 | 24 | .rows .container{ border-left: 1px solid #ddd } 25 | .rows #html-panel{ position: absolute; left: 0; top: 0; width: 50%; height: 33.33%;} 26 | .rows #css-panel{ position: absolute; left: 0; top: 33.33%; width: 50%; height: 33.33%;} 27 | .rows #js-panel{ position: absolute; left: 0; top: 66.66%; width: 50%; height: 33.33%;} 28 | .rows #output-panel{ position: absolute; left: 50%; top: 0; width: 50%; height: 50%;} 29 | .rows #console-panel{ position: absolute; left: 50%; top: 50%; width: 50%; height: 50%;} 30 | 31 | li.warning{ color: orange;} 32 | li.error{ color: red;} 33 | #sandbox{ display: none;} 34 | 35 | .CodeMirror { 36 | position: absolute; 37 | top: 25px; 38 | bottom: 0; 39 | left: 0; 40 | right: 0; 41 | height: auto; 42 | } -------------------------------------------------------------------------------- /index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 |