From 3b2d5ba9039a9fc9d88a320913ac5a589ab4a8a7 Mon Sep 17 00:00:00 2001 From: ghalestrilo Date: Thu, 30 Apr 2020 12:41:48 -0300 Subject: [PATCH] :white_check_mark: add tests for folder filename --- client/components/__test__/FileNode.test.jsx | 130 +- coverage/clover.xml | 1172 ++++++++ coverage/coverage-final.json | 24 + coverage/lcov-report/base.css | 224 ++ coverage/lcov-report/block-navigation.js | 79 + .../client/__test__/mocks/fileMock.js.html | 82 + .../client/__test__/mocks/index.html | 110 + .../client/components/Nav.jsx.html | 2425 +++++++++++++++++ .../lcov-report/client/components/index.html | 110 + coverage/lcov-report/client/constants.js.html | 511 ++++ coverage/lcov-report/client/index.html | 125 + .../modules/IDE/actions/console.js.html | 121 + .../client/modules/IDE/actions/files.js.html | 715 +++++ .../client/modules/IDE/actions/ide.js.html | 919 +++++++ .../client/modules/IDE/actions/index.html | 185 ++ .../modules/IDE/actions/preferences.js.html | 715 +++++ .../modules/IDE/actions/project.js.html | 1225 +++++++++ .../client/modules/IDE/actions/toast.js.html | 148 + .../modules/IDE/components/FileNode.jsx.html | 1057 +++++++ .../client/modules/IDE/components/index.html | 110 + .../client/modules/User/actions.js.html | 823 ++++++ .../client/modules/User/index.html | 110 + .../lcov-report/client/persistState.js.html | 160 ++ coverage/lcov-report/client/utils/index.html | 110 + .../lcov-report/client/utils/metaKey.js.html | 127 + coverage/lcov-report/index.html | 275 ++ coverage/lcov-report/prettify.css | 1 + coverage/lcov-report/prettify.js | 2 + .../project.controller/createProject.js.html | 370 +++ .../project.controller/deleteProject.js.html | 250 ++ .../getProjectsForUser.js.html | 295 ++ .../controllers/project.controller/index.html | 140 + .../user.controller/apiKey.js.html | 388 +++ .../controllers/user.controller/index.html | 110 + .../server/domain-objects/Project.js.html | 478 ++++ .../domain-objects/createDefaultFiles.js.html | 223 ++ .../server/domain-objects/index.html | 125 + coverage/lcov-report/server/models/index.html | 125 + .../lcov-report/server/models/project.js.html | 352 +++ .../lcov-report/server/models/user.js.html | 550 ++++ .../utils/createApplicationErrorClass.js.html | 178 ++ .../lcov-report/server/utils/createId.js.html | 103 + coverage/lcov-report/server/utils/index.html | 125 + coverage/lcov-report/sort-arrow-sprite.png | Bin 0 -> 209 bytes coverage/lcov-report/sorter.js | 170 ++ coverage/lcov.info | 2376 ++++++++++++++++ 46 files changed, 18137 insertions(+), 16 deletions(-) create mode 100644 coverage/clover.xml create mode 100644 coverage/coverage-final.json create mode 100644 coverage/lcov-report/base.css create mode 100644 coverage/lcov-report/block-navigation.js create mode 100644 coverage/lcov-report/client/__test__/mocks/fileMock.js.html create mode 100644 coverage/lcov-report/client/__test__/mocks/index.html create mode 100644 coverage/lcov-report/client/components/Nav.jsx.html create mode 100644 coverage/lcov-report/client/components/index.html create mode 100644 coverage/lcov-report/client/constants.js.html create mode 100644 coverage/lcov-report/client/index.html create mode 100644 coverage/lcov-report/client/modules/IDE/actions/console.js.html create mode 100644 coverage/lcov-report/client/modules/IDE/actions/files.js.html create mode 100644 coverage/lcov-report/client/modules/IDE/actions/ide.js.html create mode 100644 coverage/lcov-report/client/modules/IDE/actions/index.html create mode 100644 coverage/lcov-report/client/modules/IDE/actions/preferences.js.html create mode 100644 coverage/lcov-report/client/modules/IDE/actions/project.js.html create mode 100644 coverage/lcov-report/client/modules/IDE/actions/toast.js.html create mode 100644 coverage/lcov-report/client/modules/IDE/components/FileNode.jsx.html create mode 100644 coverage/lcov-report/client/modules/IDE/components/index.html create mode 100644 coverage/lcov-report/client/modules/User/actions.js.html create mode 100644 coverage/lcov-report/client/modules/User/index.html create mode 100644 coverage/lcov-report/client/persistState.js.html create mode 100644 coverage/lcov-report/client/utils/index.html create mode 100644 coverage/lcov-report/client/utils/metaKey.js.html create mode 100644 coverage/lcov-report/index.html create mode 100644 coverage/lcov-report/prettify.css create mode 100644 coverage/lcov-report/prettify.js create mode 100644 coverage/lcov-report/server/controllers/project.controller/createProject.js.html create mode 100644 coverage/lcov-report/server/controllers/project.controller/deleteProject.js.html create mode 100644 coverage/lcov-report/server/controllers/project.controller/getProjectsForUser.js.html create mode 100644 coverage/lcov-report/server/controllers/project.controller/index.html create mode 100644 coverage/lcov-report/server/controllers/user.controller/apiKey.js.html create mode 100644 coverage/lcov-report/server/controllers/user.controller/index.html create mode 100644 coverage/lcov-report/server/domain-objects/Project.js.html create mode 100644 coverage/lcov-report/server/domain-objects/createDefaultFiles.js.html create mode 100644 coverage/lcov-report/server/domain-objects/index.html create mode 100644 coverage/lcov-report/server/models/index.html create mode 100644 coverage/lcov-report/server/models/project.js.html create mode 100644 coverage/lcov-report/server/models/user.js.html create mode 100644 coverage/lcov-report/server/utils/createApplicationErrorClass.js.html create mode 100644 coverage/lcov-report/server/utils/createId.js.html create mode 100644 coverage/lcov-report/server/utils/index.html create mode 100644 coverage/lcov-report/sort-arrow-sprite.png create mode 100644 coverage/lcov-report/sorter.js create mode 100644 coverage/lcov.info diff --git a/client/components/__test__/FileNode.test.jsx b/client/components/__test__/FileNode.test.jsx index 60eededb..81fcb452 100644 --- a/client/components/__test__/FileNode.test.jsx +++ b/client/components/__test__/FileNode.test.jsx @@ -6,15 +6,52 @@ beforeAll(() => {}); describe('', () => { let component; let props = {}; + let input; + let renameTriggerButton; + const changeName = (newFileName) => { + renameTriggerButton.simulate('click'); + input.simulate('change', { target: { value: newFileName } }); + input.simulate('blur'); + }; + const getState = () => component.state(); + const getUpdatedName = () => getState().updatedName; - describe('with valid props', () => { + describe('with valid props, regardless of filetype', () => { + [''].forEach((fileType) => { + beforeEach(() => { + props = { + ...props, + id: '0', + name: 'test.jsx', + fileType, + canEdit: true, + children: [], + authenticated: false, + setSelectedFile: jest.fn(), + deleteFile: jest.fn(), + updateFileName: jest.fn(), + resetSelectedFile: jest.fn(), + newFile: jest.fn(), + newFolder: jest.fn(), + showFolderChildren: jest.fn(), + hideFolderChildren: jest.fn(), + openUploadFileModal: jest.fn() + }; + component = shallow(); + }); + }); + }); + + describe('as file with valid props', () => { beforeEach(() => { props = { ...props, id: '0', - children: [], name: 'test.jsx', - fileType: 'dunno', + fileType: 'file', + canEdit: true, + children: [], + authenticated: false, setSelectedFile: jest.fn(), deleteFile: jest.fn(), updateFileName: jest.fn(), @@ -23,22 +60,12 @@ describe('', () => { newFolder: jest.fn(), showFolderChildren: jest.fn(), hideFolderChildren: jest.fn(), - canEdit: true, - authenticated: false, openUploadFileModal: jest.fn() }; component = shallow(); }); describe('when changing name', () => { - let input; - let renameTriggerButton; - const changeName = (newFileName) => { - renameTriggerButton.simulate('click'); - input.simulate('change', { target: { value: newFileName } }); - input.simulate('blur'); - }; - beforeEach(() => { input = component.find('.sidebar__file-item-input'); renameTriggerButton = component @@ -55,17 +82,88 @@ describe('', () => { beforeEach(() => changeName(newName)); it('should save the name', () => { + console.log('component.state'); + console.log(component.state()); expect(props.updateFileName).toBeCalledWith(props.id, newName); }); }); + // Failure Scenarios + describe('to an empty filename', () => { const newName = ''; beforeEach(() => changeName(newName)); - it('should not save the name', () => { - expect(props.updateFileName).not.toHaveBeenCalled(); - }); + + it('should not save', () => expect(props.updateFileName).not.toHaveBeenCalled()); + it('should reset name', () => expect(getUpdatedName()).toEqual(props.name)); + }); + + describe('to an extensionless filename', () => { + const newName = 'extensionless'; + beforeEach(() => changeName(newName)); + + it('should not save', () => expect(props.updateFileName).not.toHaveBeenCalled()); + it('should reset name', () => expect(getUpdatedName()).toEqual(props.name)); + }); + + describe('to different extension', () => { + const newName = 'name.gif'; + beforeEach(() => changeName(newName)); + + it('should not save', () => expect(props.updateFileName).not.toHaveBeenCalled()); + it('should reset name', () => expect(getUpdatedName()).toEqual(props.name)); + }); + + describe('to just an extension', () => { + const newName = '.jsx'; + beforeEach(() => changeName(newName)); + + it('should not save', () => expect(props.updateFileName).not.toHaveBeenCalled()); + it('should reset name', () => expect(getUpdatedName()).toEqual(props.name)); + }); + }); + }); + + + describe('as folder with valid props', () => { + beforeEach(() => { + props = { + ...props, + id: '0', + children: [], + name: 'filename', + fileType: 'folder', + canEdit: true, + authenticated: false, + setSelectedFile: jest.fn(), + deleteFile: jest.fn(), + updateFileName: jest.fn(), + resetSelectedFile: jest.fn(), + newFile: jest.fn(), + newFolder: jest.fn(), + showFolderChildren: jest.fn(), + hideFolderChildren: jest.fn(), + openUploadFileModal: jest.fn() + }; + component = shallow(); + }); + + describe('when changing name', () => { + beforeEach(() => { + input = component.find('.sidebar__file-item-input'); + renameTriggerButton = component + .find('.sidebar__file-item-option') + .first(); + component.setState({ isEditing: true }); + }); + + describe('to a filename', () => { + const newName = 'filename.jsx'; + beforeEach(() => changeName(newName)); + + it('should not save', () => expect(props.updateFileName).not.toHaveBeenCalled()); + it('should reset name', () => expect(getUpdatedName()).toEqual(props.name)); }); }); }); diff --git a/coverage/clover.xml b/coverage/clover.xml new file mode 100644 index 00000000..0110d29c --- /dev/null +++ b/coverage/clover.xml @@ -0,0 +1,1172 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/coverage/coverage-final.json b/coverage/coverage-final.json new file mode 100644 index 00000000..1eb2d7f3 --- /dev/null +++ b/coverage/coverage-final.json @@ -0,0 +1,24 @@ +{"/home/lalis/git/p5.js-web-editor/client/constants.js": {"path":"/home/lalis/git/p5.js-web-editor/client/constants.js","statementMap":{"0":{"start":{"line":3,"column":35},"end":{"line":3,"column":56}},"1":{"start":{"line":4,"column":29},"end":{"line":4,"column":44}},"2":{"start":{"line":6,"column":28},"end":{"line":6,"column":42}},"3":{"start":{"line":7,"column":27},"end":{"line":7,"column":40}},"4":{"start":{"line":9,"column":39},"end":{"line":9,"column":64}},"5":{"start":{"line":10,"column":38},"end":{"line":10,"column":62}},"6":{"start":{"line":12,"column":32},"end":{"line":12,"column":50}},"7":{"start":{"line":13,"column":33},"end":{"line":13,"column":52}},"8":{"start":{"line":14,"column":29},"end":{"line":14,"column":44}},"9":{"start":{"line":15,"column":32},"end":{"line":15,"column":50}},"10":{"start":{"line":17,"column":25},"end":{"line":17,"column":36}},"11":{"start":{"line":18,"column":27},"end":{"line":18,"column":40}},"12":{"start":{"line":19,"column":26},"end":{"line":19,"column":38}},"13":{"start":{"line":21,"column":32},"end":{"line":21,"column":50}},"14":{"start":{"line":23,"column":31},"end":{"line":23,"column":48}},"15":{"start":{"line":24,"column":31},"end":{"line":24,"column":48}},"16":{"start":{"line":26,"column":32},"end":{"line":26,"column":50}},"17":{"start":{"line":27,"column":30},"end":{"line":27,"column":46}},"18":{"start":{"line":29,"column":36},"end":{"line":29,"column":58}},"19":{"start":{"line":30,"column":33},"end":{"line":30,"column":52}},"20":{"start":{"line":31,"column":27},"end":{"line":31,"column":40}},"21":{"start":{"line":32,"column":29},"end":{"line":32,"column":44}},"22":{"start":{"line":33,"column":38},"end":{"line":33,"column":62}},"23":{"start":{"line":34,"column":38},"end":{"line":34,"column":62}},"24":{"start":{"line":36,"column":27},"end":{"line":36,"column":40}},"25":{"start":{"line":37,"column":28},"end":{"line":37,"column":42}},"26":{"start":{"line":39,"column":31},"end":{"line":39,"column":48}},"27":{"start":{"line":40,"column":33},"end":{"line":40,"column":53}},"28":{"start":{"line":41,"column":33},"end":{"line":41,"column":52}},"29":{"start":{"line":43,"column":33},"end":{"line":43,"column":52}},"30":{"start":{"line":44,"column":38},"end":{"line":44,"column":62}},"31":{"start":{"line":45,"column":31},"end":{"line":45,"column":48}},"32":{"start":{"line":47,"column":30},"end":{"line":47,"column":46}},"33":{"start":{"line":49,"column":33},"end":{"line":49,"column":52}},"34":{"start":{"line":50,"column":26},"end":{"line":50,"column":38}},"35":{"start":{"line":51,"column":26},"end":{"line":51,"column":38}},"36":{"start":{"line":52,"column":27},"end":{"line":52,"column":40}},"37":{"start":{"line":53,"column":28},"end":{"line":53,"column":42}},"38":{"start":{"line":55,"column":30},"end":{"line":55,"column":46}},"39":{"start":{"line":56,"column":32},"end":{"line":56,"column":50}},"40":{"start":{"line":58,"column":29},"end":{"line":58,"column":44}},"41":{"start":{"line":59,"column":29},"end":{"line":59,"column":44}},"42":{"start":{"line":60,"column":30},"end":{"line":60,"column":46}},"43":{"start":{"line":61,"column":32},"end":{"line":61,"column":50}},"44":{"start":{"line":63,"column":35},"end":{"line":63,"column":56}},"45":{"start":{"line":64,"column":34},"end":{"line":64,"column":54}},"46":{"start":{"line":66,"column":32},"end":{"line":66,"column":50}},"47":{"start":{"line":67,"column":27},"end":{"line":67,"column":40}},"48":{"start":{"line":69,"column":28},"end":{"line":69,"column":42}},"49":{"start":{"line":70,"column":28},"end":{"line":70,"column":42}},"50":{"start":{"line":71,"column":32},"end":{"line":71,"column":50}},"51":{"start":{"line":72,"column":31},"end":{"line":72,"column":48}},"52":{"start":{"line":73,"column":31},"end":{"line":73,"column":48}},"53":{"start":{"line":74,"column":31},"end":{"line":74,"column":48}},"54":{"start":{"line":75,"column":32},"end":{"line":75,"column":50}},"55":{"start":{"line":77,"column":36},"end":{"line":77,"column":58}},"56":{"start":{"line":78,"column":37},"end":{"line":78,"column":60}},"57":{"start":{"line":79,"column":37},"end":{"line":79,"column":60}},"58":{"start":{"line":80,"column":38},"end":{"line":80,"column":62}},"59":{"start":{"line":81,"column":36},"end":{"line":81,"column":58}},"60":{"start":{"line":82,"column":36},"end":{"line":82,"column":58}},"61":{"start":{"line":83,"column":38},"end":{"line":83,"column":62}},"62":{"start":{"line":84,"column":39},"end":{"line":84,"column":64}},"63":{"start":{"line":86,"column":32},"end":{"line":86,"column":50}},"64":{"start":{"line":87,"column":33},"end":{"line":87,"column":52}},"65":{"start":{"line":88,"column":35},"end":{"line":88,"column":56}},"66":{"start":{"line":89,"column":36},"end":{"line":89,"column":58}},"67":{"start":{"line":90,"column":44},"end":{"line":90,"column":74}},"68":{"start":{"line":91,"column":45},"end":{"line":91,"column":76}},"69":{"start":{"line":92,"column":26},"end":{"line":92,"column":38}},"70":{"start":{"line":93,"column":26},"end":{"line":93,"column":38}},"71":{"start":{"line":94,"column":30},"end":{"line":94,"column":46}},"72":{"start":{"line":95,"column":25},"end":{"line":95,"column":36}},"73":{"start":{"line":97,"column":35},"end":{"line":97,"column":56}},"74":{"start":{"line":98,"column":31},"end":{"line":98,"column":48}},"75":{"start":{"line":99,"column":36},"end":{"line":99,"column":58}},"76":{"start":{"line":100,"column":34},"end":{"line":100,"column":54}},"77":{"start":{"line":102,"column":37},"end":{"line":102,"column":60}},"78":{"start":{"line":103,"column":36},"end":{"line":103,"column":58}},"79":{"start":{"line":105,"column":39},"end":{"line":105,"column":64}},"80":{"start":{"line":106,"column":36},"end":{"line":106,"column":58}},"81":{"start":{"line":107,"column":44},"end":{"line":107,"column":74}},"82":{"start":{"line":109,"column":43},"end":{"line":109,"column":72}},"83":{"start":{"line":110,"column":41},"end":{"line":110,"column":68}},"84":{"start":{"line":111,"column":43},"end":{"line":111,"column":72}},"85":{"start":{"line":112,"column":42},"end":{"line":112,"column":70}},"86":{"start":{"line":115,"column":21},"end":{"line":115,"column":28}},"87":{"start":{"line":117,"column":35},"end":{"line":117,"column":56}},"88":{"start":{"line":118,"column":41},"end":{"line":118,"column":68}},"89":{"start":{"line":120,"column":38},"end":{"line":120,"column":62}},"90":{"start":{"line":121,"column":40},"end":{"line":121,"column":66}},"91":{"start":{"line":122,"column":33},"end":{"line":122,"column":52}},"92":{"start":{"line":123,"column":32},"end":{"line":123,"column":50}},"93":{"start":{"line":124,"column":32},"end":{"line":124,"column":50}},"94":{"start":{"line":126,"column":29},"end":{"line":126,"column":44}},"95":{"start":{"line":127,"column":37},"end":{"line":127,"column":60}},"96":{"start":{"line":129,"column":42},"end":{"line":129,"column":70}},"97":{"start":{"line":130,"column":42},"end":{"line":130,"column":70}},"98":{"start":{"line":131,"column":26},"end":{"line":131,"column":38}},"99":{"start":{"line":132,"column":28},"end":{"line":132,"column":42}},"100":{"start":{"line":134,"column":32},"end":{"line":134,"column":50}},"101":{"start":{"line":135,"column":27},"end":{"line":135,"column":40}},"102":{"start":{"line":136,"column":31},"end":{"line":136,"column":48}},"103":{"start":{"line":137,"column":31},"end":{"line":137,"column":48}},"104":{"start":{"line":138,"column":38},"end":{"line":138,"column":62}},"105":{"start":{"line":140,"column":29},"end":{"line":140,"column":44}},"106":{"start":{"line":141,"column":28},"end":{"line":141,"column":42}},"107":{"start":{"line":143,"column":36},"end":{"line":143,"column":58}},"108":{"start":{"line":144,"column":34},"end":{"line":144,"column":54}}},"fnMap":{},"branchMap":{},"s":{"0":2,"1":2,"2":2,"3":2,"4":2,"5":2,"6":2,"7":2,"8":2,"9":2,"10":2,"11":2,"12":2,"13":2,"14":2,"15":2,"16":2,"17":2,"18":2,"19":2,"20":2,"21":2,"22":2,"23":2,"24":2,"25":2,"26":2,"27":2,"28":2,"29":2,"30":2,"31":2,"32":2,"33":2,"34":2,"35":2,"36":2,"37":2,"38":2,"39":2,"40":2,"41":2,"42":2,"43":2,"44":2,"45":2,"46":2,"47":2,"48":2,"49":2,"50":2,"51":2,"52":2,"53":2,"54":2,"55":2,"56":2,"57":2,"58":2,"59":2,"60":2,"61":2,"62":2,"63":2,"64":2,"65":2,"66":2,"67":2,"68":2,"69":2,"70":2,"71":2,"72":2,"73":2,"74":2,"75":2,"76":2,"77":2,"78":2,"79":2,"80":2,"81":2,"82":2,"83":2,"84":2,"85":2,"86":2,"87":2,"88":2,"89":2,"90":2,"91":2,"92":2,"93":2,"94":2,"95":2,"96":2,"97":2,"98":2,"99":2,"100":2,"101":2,"102":2,"103":2,"104":2,"105":2,"106":2,"107":2,"108":2},"f":{},"b":{},"_coverageSchema":"43e27e138ebf9cfc5966b082cf9a028302ed4184","hash":"b1618d7a8f0a8f0cab9864878f4e77a62c1035da"} +,"/home/lalis/git/p5.js-web-editor/client/persistState.js": {"path":"/home/lalis/git/p5.js-web-editor/client/persistState.js","statementMap":{"0":{"start":{"line":5,"column":12},"end":{"line":5,"column":25}},"1":{"start":{"line":6,"column":16},"end":{"line":6,"column":30}},"2":{"start":{"line":8,"column":25},"end":{"line":14,"column":1}},"3":{"start":{"line":9,"column":2},"end":{"line":13,"column":3}},"4":{"start":{"line":10,"column":4},"end":{"line":10,"column":48}},"5":{"start":{"line":12,"column":4},"end":{"line":12,"column":63}},"6":{"start":{"line":16,"column":25},"end":{"line":23,"column":1}},"7":{"start":{"line":17,"column":2},"end":{"line":22,"column":3}},"8":{"start":{"line":18,"column":4},"end":{"line":18,"column":44}},"9":{"start":{"line":20,"column":4},"end":{"line":20,"column":77}},"10":{"start":{"line":21,"column":4},"end":{"line":21,"column":16}},"11":{"start":{"line":25,"column":26},"end":{"line":27,"column":1}},"12":{"start":{"line":26,"column":2},"end":{"line":26,"column":26}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":8,"column":25},"end":{"line":8,"column":26}},"loc":{"start":{"line":8,"column":36},"end":{"line":14,"column":1}},"line":8},"1":{"name":"(anonymous_1)","decl":{"start":{"line":16,"column":25},"end":{"line":16,"column":26}},"loc":{"start":{"line":16,"column":31},"end":{"line":23,"column":1}},"line":16},"2":{"name":"(anonymous_2)","decl":{"start":{"line":25,"column":26},"end":{"line":25,"column":27}},"loc":{"start":{"line":25,"column":32},"end":{"line":27,"column":1}},"line":25}},"branchMap":{},"s":{"0":2,"1":2,"2":2,"3":0,"4":0,"5":0,"6":2,"7":0,"8":0,"9":0,"10":0,"11":2,"12":0},"f":{"0":0,"1":0,"2":0},"b":{},"_coverageSchema":"43e27e138ebf9cfc5966b082cf9a028302ed4184","hash":"352dc623e22fbe329f5e5db408c2a31bb3bed4db"} +,"/home/lalis/git/p5.js-web-editor/client/__test__/mocks/fileMock.js": {"path":"/home/lalis/git/p5.js-web-editor/client/__test__/mocks/fileMock.js","statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":34}}},"fnMap":{},"branchMap":{},"s":{"0":2},"f":{},"b":{},"_coverageSchema":"43e27e138ebf9cfc5966b082cf9a028302ed4184","hash":"faa55ea1eaba07f5b29c691847526bb48cb617e2"} +,"/home/lalis/git/p5.js-web-editor/client/components/Nav.jsx": {"path":"/home/lalis/git/p5.js-web-editor/client/components/Nav.jsx","statementMap":{"0":{"start":{"line":17,"column":20},"end":{"line":17,"column":65}},"1":{"start":{"line":18,"column":16},"end":{"line":18,"column":56}},"2":{"start":{"line":20,"column":18},"end":{"line":20,"column":75}},"3":{"start":{"line":24,"column":4},"end":{"line":24,"column":17}},"4":{"start":{"line":25,"column":4},"end":{"line":27,"column":6}},"5":{"start":{"line":28,"column":4},"end":{"line":28,"column":51}},"6":{"start":{"line":29,"column":4},"end":{"line":29,"column":49}},"7":{"start":{"line":30,"column":4},"end":{"line":30,"column":61}},"8":{"start":{"line":31,"column":4},"end":{"line":31,"column":51}},"9":{"start":{"line":32,"column":4},"end":{"line":32,"column":65}},"10":{"start":{"line":33,"column":4},"end":{"line":33,"column":49}},"11":{"start":{"line":34,"column":4},"end":{"line":34,"column":47}},"12":{"start":{"line":35,"column":4},"end":{"line":35,"column":59}},"13":{"start":{"line":36,"column":4},"end":{"line":36,"column":51}},"14":{"start":{"line":37,"column":4},"end":{"line":37,"column":57}},"15":{"start":{"line":38,"column":4},"end":{"line":38,"column":49}},"16":{"start":{"line":39,"column":4},"end":{"line":39,"column":55}},"17":{"start":{"line":40,"column":4},"end":{"line":40,"column":59}},"18":{"start":{"line":41,"column":4},"end":{"line":41,"column":57}},"19":{"start":{"line":42,"column":4},"end":{"line":42,"column":47}},"20":{"start":{"line":43,"column":4},"end":{"line":43,"column":65}},"21":{"start":{"line":44,"column":4},"end":{"line":44,"column":49}},"22":{"start":{"line":45,"column":4},"end":{"line":45,"column":71}},"23":{"start":{"line":46,"column":4},"end":{"line":46,"column":69}},"24":{"start":{"line":47,"column":4},"end":{"line":47,"column":75}},"25":{"start":{"line":48,"column":4},"end":{"line":48,"column":53}},"26":{"start":{"line":49,"column":4},"end":{"line":49,"column":72}},"27":{"start":{"line":50,"column":4},"end":{"line":50,"column":66}},"28":{"start":{"line":51,"column":4},"end":{"line":51,"column":66}},"29":{"start":{"line":52,"column":4},"end":{"line":52,"column":72}},"30":{"start":{"line":53,"column":4},"end":{"line":53,"column":66}},"31":{"start":{"line":54,"column":4},"end":{"line":54,"column":76}},"32":{"start":{"line":55,"column":4},"end":{"line":55,"column":70}},"33":{"start":{"line":56,"column":4},"end":{"line":56,"column":72}},"34":{"start":{"line":57,"column":4},"end":{"line":57,"column":66}},"35":{"start":{"line":58,"column":4},"end":{"line":58,"column":78}},"36":{"start":{"line":59,"column":4},"end":{"line":59,"column":72}},"37":{"start":{"line":60,"column":4},"end":{"line":60,"column":55}},"38":{"start":{"line":64,"column":4},"end":{"line":64,"column":68}},"39":{"start":{"line":65,"column":4},"end":{"line":65,"column":68}},"40":{"start":{"line":68,"column":4},"end":{"line":68,"column":71}},"41":{"start":{"line":69,"column":4},"end":{"line":69,"column":71}},"42":{"start":{"line":73,"column":4},"end":{"line":75,"column":7}},"43":{"start":{"line":79,"column":4},"end":{"line":81,"column":5}},"44":{"start":{"line":80,"column":6},"end":{"line":80,"column":31}},"45":{"start":{"line":85,"column":4},"end":{"line":87,"column":5}},"46":{"start":{"line":86,"column":6},"end":{"line":86,"column":13}},"47":{"start":{"line":88,"column":4},"end":{"line":90,"column":5}},"48":{"start":{"line":89,"column":6},"end":{"line":89,"column":13}},"49":{"start":{"line":92,"column":4},"end":{"line":92,"column":30}},"50":{"start":{"line":96,"column":53},"end":{"line":96,"column":63}},"51":{"start":{"line":97,"column":4},"end":{"line":105,"column":5}},"52":{"start":{"line":98,"column":6},"end":{"line":98,"column":33}},"53":{"start":{"line":99,"column":6},"end":{"line":99,"column":52}},"54":{"start":{"line":100,"column":6},"end":{"line":100,"column":30}},"55":{"start":{"line":101,"column":11},"end":{"line":105,"column":5}},"56":{"start":{"line":102,"column":6},"end":{"line":102,"column":33}},"57":{"start":{"line":103,"column":6},"end":{"line":103,"column":52}},"58":{"start":{"line":104,"column":6},"end":{"line":104,"column":30}},"59":{"start":{"line":106,"column":4},"end":{"line":106,"column":29}},"60":{"start":{"line":110,"column":4},"end":{"line":114,"column":5}},"61":{"start":{"line":111,"column":6},"end":{"line":111,"column":67}},"62":{"start":{"line":113,"column":6},"end":{"line":113,"column":55}},"63":{"start":{"line":115,"column":4},"end":{"line":115,"column":29}},"64":{"start":{"line":119,"column":4},"end":{"line":119,"column":39}},"65":{"start":{"line":120,"column":4},"end":{"line":120,"column":29}},"66":{"start":{"line":124,"column":4},"end":{"line":124,"column":39}},"67":{"start":{"line":125,"column":4},"end":{"line":125,"column":29}},"68":{"start":{"line":129,"column":4},"end":{"line":129,"column":39}},"69":{"start":{"line":130,"column":4},"end":{"line":130,"column":29}},"70":{"start":{"line":134,"column":4},"end":{"line":134,"column":47}},"71":{"start":{"line":135,"column":4},"end":{"line":135,"column":29}},"72":{"start":{"line":139,"column":4},"end":{"line":139,"column":49}},"73":{"start":{"line":140,"column":4},"end":{"line":140,"column":29}},"74":{"start":{"line":144,"column":4},"end":{"line":144,"column":29}},"75":{"start":{"line":145,"column":4},"end":{"line":145,"column":29}},"76":{"start":{"line":149,"column":4},"end":{"line":149,"column":28}},"77":{"start":{"line":150,"column":4},"end":{"line":150,"column":29}},"78":{"start":{"line":154,"column":4},"end":{"line":154,"column":44}},"79":{"start":{"line":155,"column":4},"end":{"line":155,"column":29}},"80":{"start":{"line":159,"column":4},"end":{"line":159,"column":45}},"81":{"start":{"line":160,"column":4},"end":{"line":160,"column":29}},"82":{"start":{"line":164,"column":4},"end":{"line":164,"column":43}},"83":{"start":{"line":165,"column":4},"end":{"line":165,"column":29}},"84":{"start":{"line":169,"column":4},"end":{"line":169,"column":28}},"85":{"start":{"line":170,"column":4},"end":{"line":170,"column":29}},"86":{"start":{"line":174,"column":4},"end":{"line":174,"column":33}},"87":{"start":{"line":175,"column":4},"end":{"line":175,"column":61}},"88":{"start":{"line":176,"column":4},"end":{"line":176,"column":29}},"89":{"start":{"line":180,"column":4},"end":{"line":180,"column":30}},"90":{"start":{"line":181,"column":4},"end":{"line":181,"column":29}},"91":{"start":{"line":185,"column":25},"end":{"line":185,"column":42}},"92":{"start":{"line":186,"column":4},"end":{"line":186,"column":88}},"93":{"start":{"line":187,"column":4},"end":{"line":187,"column":29}},"94":{"start":{"line":191,"column":4},"end":{"line":193,"column":7}},"95":{"start":{"line":197,"column":4},"end":{"line":205,"column":5}},"96":{"start":{"line":198,"column":6},"end":{"line":200,"column":9}},"97":{"start":{"line":202,"column":6},"end":{"line":204,"column":9}},"98":{"start":{"line":209,"column":4},"end":{"line":209,"column":90}},"99":{"start":{"line":213,"column":4},"end":{"line":213,"column":28}},"100":{"start":{"line":214,"column":4},"end":{"line":214,"column":31}},"101":{"start":{"line":218,"column":4},"end":{"line":221,"column":5}},"102":{"start":{"line":219,"column":6},"end":{"line":219,"column":31}},"103":{"start":{"line":220,"column":6},"end":{"line":220,"column":24}},"104":{"start":{"line":225,"column":4},"end":{"line":225,"column":69}},"105":{"start":{"line":229,"column":4},"end":{"line":243,"column":6}},"106":{"start":{"line":247,"column":4},"end":{"line":537,"column":6}},"107":{"start":{"line":258,"column":14},"end":{"line":260,"column":15}},"108":{"start":{"line":259,"column":16},"end":{"line":259,"column":41}},"109":{"start":{"line":360,"column":14},"end":{"line":362,"column":15}},"110":{"start":{"line":361,"column":16},"end":{"line":361,"column":41}},"111":{"start":{"line":372,"column":18},"end":{"line":372,"column":53}},"112":{"start":{"line":373,"column":18},"end":{"line":373,"column":43}},"113":{"start":{"line":420,"column":14},"end":{"line":422,"column":15}},"114":{"start":{"line":421,"column":16},"end":{"line":421,"column":43}},"115":{"start":{"line":495,"column":14},"end":{"line":497,"column":15}},"116":{"start":{"line":496,"column":16},"end":{"line":496,"column":41}},"117":{"start":{"line":541,"column":4},"end":{"line":555,"column":6}},"118":{"start":{"line":559,"column":4},"end":{"line":635,"column":6}},"119":{"start":{"line":572,"column":14},"end":{"line":574,"column":15}},"120":{"start":{"line":573,"column":16},"end":{"line":573,"column":44}},"121":{"start":{"line":639,"column":27},"end":{"line":639,"column":54}},"122":{"start":{"line":640,"column":28},"end":{"line":640,"column":57}},"123":{"start":{"line":642,"column":4},"end":{"line":646,"column":5}},"124":{"start":{"line":643,"column":6},"end":{"line":643,"column":64}},"125":{"start":{"line":644,"column":11},"end":{"line":646,"column":5}},"126":{"start":{"line":645,"column":6},"end":{"line":645,"column":66}},"127":{"start":{"line":648,"column":4},"end":{"line":648,"column":16}},"128":{"start":{"line":652,"column":4},"end":{"line":658,"column":5}},"129":{"start":{"line":654,"column":8},"end":{"line":654,"column":58}},"130":{"start":{"line":657,"column":8},"end":{"line":657,"column":56}},"131":{"start":{"line":662,"column":29},"end":{"line":683,"column":5}},"132":{"start":{"line":685,"column":4},"end":{"line":701,"column":6}},"133":{"start":{"line":686,"column":68},"end":{"line":686,"column":85}},"134":{"start":{"line":705,"column":0},"end":{"line":749,"column":2}},"135":{"start":{"line":751,"column":0},"end":{"line":762,"column":2}},"136":{"start":{"line":765,"column":2},"end":{"line":770,"column":4}},"137":{"start":{"line":769,"column":41},"end":{"line":769,"column":61}},"138":{"start":{"line":773,"column":27},"end":{"line":779,"column":1}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":23,"column":2},"end":{"line":23,"column":3}},"loc":{"start":{"line":23,"column":21},"end":{"line":61,"column":3}},"line":23},"1":{"name":"(anonymous_1)","decl":{"start":{"line":63,"column":2},"end":{"line":63,"column":3}},"loc":{"start":{"line":63,"column":22},"end":{"line":66,"column":3}},"line":63},"2":{"name":"(anonymous_2)","decl":{"start":{"line":67,"column":2},"end":{"line":67,"column":3}},"loc":{"start":{"line":67,"column":25},"end":{"line":70,"column":3}},"line":67},"3":{"name":"(anonymous_3)","decl":{"start":{"line":72,"column":2},"end":{"line":72,"column":3}},"loc":{"start":{"line":72,"column":24},"end":{"line":76,"column":3}},"line":72},"4":{"name":"(anonymous_4)","decl":{"start":{"line":78,"column":2},"end":{"line":78,"column":3}},"loc":{"start":{"line":78,"column":19},"end":{"line":82,"column":3}},"line":78},"5":{"name":"(anonymous_5)","decl":{"start":{"line":84,"column":2},"end":{"line":84,"column":3}},"loc":{"start":{"line":84,"column":17},"end":{"line":93,"column":3}},"line":84},"6":{"name":"(anonymous_6)","decl":{"start":{"line":95,"column":2},"end":{"line":95,"column":3}},"loc":{"start":{"line":95,"column":14},"end":{"line":107,"column":3}},"line":95},"7":{"name":"(anonymous_7)","decl":{"start":{"line":109,"column":2},"end":{"line":109,"column":3}},"loc":{"start":{"line":109,"column":15},"end":{"line":116,"column":3}},"line":109},"8":{"name":"(anonymous_8)","decl":{"start":{"line":118,"column":2},"end":{"line":118,"column":3}},"loc":{"start":{"line":118,"column":15},"end":{"line":121,"column":3}},"line":118},"9":{"name":"(anonymous_9)","decl":{"start":{"line":123,"column":2},"end":{"line":123,"column":3}},"loc":{"start":{"line":123,"column":19},"end":{"line":126,"column":3}},"line":123},"10":{"name":"(anonymous_10)","decl":{"start":{"line":128,"column":2},"end":{"line":128,"column":3}},"loc":{"start":{"line":128,"column":23},"end":{"line":131,"column":3}},"line":128},"11":{"name":"(anonymous_11)","decl":{"start":{"line":133,"column":2},"end":{"line":133,"column":3}},"loc":{"start":{"line":133,"column":18},"end":{"line":136,"column":3}},"line":133},"12":{"name":"(anonymous_12)","decl":{"start":{"line":138,"column":2},"end":{"line":138,"column":3}},"loc":{"start":{"line":138,"column":20},"end":{"line":141,"column":3}},"line":138},"13":{"name":"(anonymous_13)","decl":{"start":{"line":143,"column":2},"end":{"line":143,"column":3}},"loc":{"start":{"line":143,"column":14},"end":{"line":146,"column":3}},"line":143},"14":{"name":"(anonymous_14)","decl":{"start":{"line":148,"column":2},"end":{"line":148,"column":3}},"loc":{"start":{"line":148,"column":15},"end":{"line":151,"column":3}},"line":148},"15":{"name":"(anonymous_15)","decl":{"start":{"line":153,"column":2},"end":{"line":153,"column":3}},"loc":{"start":{"line":153,"column":26},"end":{"line":156,"column":3}},"line":153},"16":{"name":"(anonymous_16)","decl":{"start":{"line":158,"column":2},"end":{"line":158,"column":3}},"loc":{"start":{"line":158,"column":25},"end":{"line":161,"column":3}},"line":158},"17":{"name":"(anonymous_17)","decl":{"start":{"line":163,"column":2},"end":{"line":163,"column":3}},"loc":{"start":{"line":163,"column":28},"end":{"line":166,"column":3}},"line":163},"18":{"name":"(anonymous_18)","decl":{"start":{"line":168,"column":2},"end":{"line":168,"column":3}},"loc":{"start":{"line":168,"column":17},"end":{"line":171,"column":3}},"line":168},"19":{"name":"(anonymous_19)","decl":{"start":{"line":173,"column":2},"end":{"line":173,"column":3}},"loc":{"start":{"line":173,"column":19},"end":{"line":177,"column":3}},"line":173},"20":{"name":"(anonymous_20)","decl":{"start":{"line":179,"column":2},"end":{"line":179,"column":3}},"loc":{"start":{"line":179,"column":20},"end":{"line":182,"column":3}},"line":179},"21":{"name":"(anonymous_21)","decl":{"start":{"line":184,"column":2},"end":{"line":184,"column":3}},"loc":{"start":{"line":184,"column":16},"end":{"line":188,"column":3}},"line":184},"22":{"name":"(anonymous_22)","decl":{"start":{"line":190,"column":2},"end":{"line":190,"column":3}},"loc":{"start":{"line":190,"column":23},"end":{"line":194,"column":3}},"line":190},"23":{"name":"(anonymous_23)","decl":{"start":{"line":196,"column":2},"end":{"line":196,"column":3}},"loc":{"start":{"line":196,"column":27},"end":{"line":206,"column":3}},"line":196},"24":{"name":"(anonymous_24)","decl":{"start":{"line":208,"column":2},"end":{"line":208,"column":3}},"loc":{"start":{"line":208,"column":16},"end":{"line":210,"column":3}},"line":208},"25":{"name":"(anonymous_25)","decl":{"start":{"line":212,"column":2},"end":{"line":212,"column":3}},"loc":{"start":{"line":212,"column":24},"end":{"line":215,"column":3}},"line":212},"26":{"name":"(anonymous_26)","decl":{"start":{"line":217,"column":2},"end":{"line":217,"column":3}},"loc":{"start":{"line":217,"column":21},"end":{"line":222,"column":3}},"line":217},"27":{"name":"(anonymous_27)","decl":{"start":{"line":224,"column":2},"end":{"line":224,"column":3}},"loc":{"start":{"line":224,"column":15},"end":{"line":226,"column":3}},"line":224},"28":{"name":"(anonymous_28)","decl":{"start":{"line":228,"column":2},"end":{"line":228,"column":3}},"loc":{"start":{"line":228,"column":40},"end":{"line":244,"column":3}},"line":228},"29":{"name":"(anonymous_29)","decl":{"start":{"line":246,"column":2},"end":{"line":246,"column":3}},"loc":{"start":{"line":246,"column":38},"end":{"line":538,"column":3}},"line":246},"30":{"name":"(anonymous_30)","decl":{"start":{"line":257,"column":25},"end":{"line":257,"column":26}},"loc":{"start":{"line":257,"column":31},"end":{"line":261,"column":13}},"line":257},"31":{"name":"(anonymous_31)","decl":{"start":{"line":359,"column":25},"end":{"line":359,"column":26}},"loc":{"start":{"line":359,"column":31},"end":{"line":363,"column":13}},"line":359},"32":{"name":"(anonymous_32)","decl":{"start":{"line":371,"column":25},"end":{"line":371,"column":26}},"loc":{"start":{"line":371,"column":31},"end":{"line":374,"column":17}},"line":371},"33":{"name":"(anonymous_33)","decl":{"start":{"line":419,"column":25},"end":{"line":419,"column":26}},"loc":{"start":{"line":419,"column":31},"end":{"line":423,"column":13}},"line":419},"34":{"name":"(anonymous_34)","decl":{"start":{"line":494,"column":25},"end":{"line":494,"column":26}},"loc":{"start":{"line":494,"column":31},"end":{"line":498,"column":13}},"line":494},"35":{"name":"(anonymous_35)","decl":{"start":{"line":540,"column":2},"end":{"line":540,"column":3}},"loc":{"start":{"line":540,"column":50},"end":{"line":556,"column":3}},"line":540},"36":{"name":"(anonymous_36)","decl":{"start":{"line":558,"column":2},"end":{"line":558,"column":3}},"loc":{"start":{"line":558,"column":48},"end":{"line":636,"column":3}},"line":558},"37":{"name":"(anonymous_37)","decl":{"start":{"line":571,"column":25},"end":{"line":571,"column":26}},"loc":{"start":{"line":571,"column":31},"end":{"line":575,"column":13}},"line":571},"38":{"name":"(anonymous_38)","decl":{"start":{"line":638,"column":2},"end":{"line":638,"column":3}},"loc":{"start":{"line":638,"column":35},"end":{"line":649,"column":3}},"line":638},"39":{"name":"(anonymous_39)","decl":{"start":{"line":651,"column":2},"end":{"line":651,"column":3}},"loc":{"start":{"line":651,"column":37},"end":{"line":659,"column":3}},"line":651},"40":{"name":"(anonymous_40)","decl":{"start":{"line":661,"column":2},"end":{"line":661,"column":3}},"loc":{"start":{"line":661,"column":11},"end":{"line":702,"column":3}},"line":661},"41":{"name":"(anonymous_41)","decl":{"start":{"line":686,"column":56},"end":{"line":686,"column":57}},"loc":{"start":{"line":686,"column":66},"end":{"line":686,"column":87}},"line":686},"42":{"name":"mapStateToProps","decl":{"start":{"line":764,"column":9},"end":{"line":764,"column":24}},"loc":{"start":{"line":764,"column":32},"end":{"line":771,"column":1}},"line":764},"43":{"name":"(anonymous_43)","decl":{"start":{"line":769,"column":33},"end":{"line":769,"column":34}},"loc":{"start":{"line":769,"column":41},"end":{"line":769,"column":61}},"line":769}},"branchMap":{"0":{"loc":{"start":{"line":20,"column":19},"end":{"line":20,"column":66}},"type":"cond-expr","locations":[{"start":{"line":20,"column":51},"end":{"line":20,"column":57}},{"start":{"line":20,"column":60},"end":{"line":20,"column":66}}],"line":20},"1":{"loc":{"start":{"line":79,"column":4},"end":{"line":81,"column":5}},"type":"if","locations":[{"start":{"line":79,"column":4},"end":{"line":81,"column":5}},{"start":{"line":79,"column":4},"end":{"line":81,"column":5}}],"line":79},"2":{"loc":{"start":{"line":85,"column":4},"end":{"line":87,"column":5}},"type":"if","locations":[{"start":{"line":85,"column":4},"end":{"line":87,"column":5}},{"start":{"line":85,"column":4},"end":{"line":87,"column":5}}],"line":85},"3":{"loc":{"start":{"line":88,"column":4},"end":{"line":90,"column":5}},"type":"if","locations":[{"start":{"line":88,"column":4},"end":{"line":90,"column":5}},{"start":{"line":88,"column":4},"end":{"line":90,"column":5}}],"line":88},"4":{"loc":{"start":{"line":88,"column":8},"end":{"line":88,"column":49}},"type":"binary-expr","locations":[{"start":{"line":88,"column":8},"end":{"line":88,"column":17}},{"start":{"line":88,"column":21},"end":{"line":88,"column":49}}],"line":88},"5":{"loc":{"start":{"line":97,"column":4},"end":{"line":105,"column":5}},"type":"if","locations":[{"start":{"line":97,"column":4},"end":{"line":105,"column":5}},{"start":{"line":97,"column":4},"end":{"line":105,"column":5}}],"line":97},"6":{"loc":{"start":{"line":101,"column":11},"end":{"line":105,"column":5}},"type":"if","locations":[{"start":{"line":101,"column":11},"end":{"line":105,"column":5}},{"start":{"line":101,"column":11},"end":{"line":105,"column":5}}],"line":101},"7":{"loc":{"start":{"line":101,"column":15},"end":{"line":101,"column":61}},"type":"binary-expr","locations":[{"start":{"line":101,"column":15},"end":{"line":101,"column":35}},{"start":{"line":101,"column":39},"end":{"line":101,"column":61}}],"line":101},"8":{"loc":{"start":{"line":110,"column":4},"end":{"line":114,"column":5}},"type":"if","locations":[{"start":{"line":110,"column":4},"end":{"line":114,"column":5}},{"start":{"line":110,"column":4},"end":{"line":114,"column":5}}],"line":110},"9":{"loc":{"start":{"line":197,"column":4},"end":{"line":205,"column":5}},"type":"if","locations":[{"start":{"line":197,"column":4},"end":{"line":205,"column":5}},{"start":{"line":197,"column":4},"end":{"line":205,"column":5}}],"line":197},"10":{"loc":{"start":{"line":209,"column":11},"end":{"line":209,"column":89}},"type":"binary-expr","locations":[{"start":{"line":209,"column":11},"end":{"line":209,"column":35}},{"start":{"line":209,"column":39},"end":{"line":209,"column":89}}],"line":209},"11":{"loc":{"start":{"line":218,"column":4},"end":{"line":221,"column":5}},"type":"if","locations":[{"start":{"line":218,"column":4},"end":{"line":221,"column":5}},{"start":{"line":218,"column":4},"end":{"line":221,"column":5}}],"line":218},"12":{"loc":{"start":{"line":258,"column":14},"end":{"line":260,"column":15}},"type":"if","locations":[{"start":{"line":258,"column":14},"end":{"line":260,"column":15}},{"start":{"line":258,"column":14},"end":{"line":260,"column":15}}],"line":258},"13":{"loc":{"start":{"line":276,"column":14},"end":{"line":286,"column":17}},"type":"binary-expr","locations":[{"start":{"line":276,"column":14},"end":{"line":276,"column":41}},{"start":{"line":276,"column":46},"end":{"line":276,"column":71}},{"start":{"line":276,"column":75},"end":{"line":276,"column":93}},{"start":{"line":277,"column":12},"end":{"line":286,"column":17}}],"line":276},"14":{"loc":{"start":{"line":287,"column":14},"end":{"line":296,"column":17}},"type":"binary-expr","locations":[{"start":{"line":287,"column":14},"end":{"line":287,"column":35}},{"start":{"line":287,"column":39},"end":{"line":287,"column":68}},{"start":{"line":288,"column":12},"end":{"line":296,"column":17}}],"line":287},"15":{"loc":{"start":{"line":297,"column":14},"end":{"line":306,"column":17}},"type":"binary-expr","locations":[{"start":{"line":297,"column":14},"end":{"line":297,"column":35}},{"start":{"line":298,"column":12},"end":{"line":306,"column":17}}],"line":297},"16":{"loc":{"start":{"line":307,"column":14},"end":{"line":316,"column":17}},"type":"binary-expr","locations":[{"start":{"line":307,"column":14},"end":{"line":307,"column":35}},{"start":{"line":308,"column":12},"end":{"line":316,"column":17}}],"line":307},"17":{"loc":{"start":{"line":317,"column":14},"end":{"line":327,"column":17}},"type":"binary-expr","locations":[{"start":{"line":317,"column":14},"end":{"line":317,"column":43}},{"start":{"line":318,"column":12},"end":{"line":327,"column":17}}],"line":317},"18":{"loc":{"start":{"line":328,"column":13},"end":{"line":340,"column":19}},"type":"binary-expr","locations":[{"start":{"line":328,"column":13},"end":{"line":328,"column":49}},{"start":{"line":329,"column":14},"end":{"line":329,"column":43}},{"start":{"line":330,"column":14},"end":{"line":330,"column":35}},{"start":{"line":331,"column":14},"end":{"line":340,"column":19}}],"line":328},"19":{"loc":{"start":{"line":341,"column":14},"end":{"line":351,"column":17}},"type":"binary-expr","locations":[{"start":{"line":341,"column":14},"end":{"line":341,"column":44}},{"start":{"line":342,"column":12},"end":{"line":351,"column":17}}],"line":341},"20":{"loc":{"start":{"line":360,"column":14},"end":{"line":362,"column":15}},"type":"if","locations":[{"start":{"line":360,"column":14},"end":{"line":362,"column":15}},{"start":{"line":360,"column":14},"end":{"line":362,"column":15}}],"line":360},"21":{"loc":{"start":{"line":420,"column":14},"end":{"line":422,"column":15}},"type":"if","locations":[{"start":{"line":420,"column":14},"end":{"line":422,"column":15}},{"start":{"line":420,"column":14},"end":{"line":422,"column":15}}],"line":420},"22":{"loc":{"start":{"line":495,"column":14},"end":{"line":497,"column":15}},"type":"if","locations":[{"start":{"line":495,"column":14},"end":{"line":497,"column":15}},{"start":{"line":495,"column":14},"end":{"line":497,"column":15}}],"line":495},"23":{"loc":{"start":{"line":572,"column":14},"end":{"line":574,"column":15}},"type":"if","locations":[{"start":{"line":572,"column":14},"end":{"line":574,"column":15}},{"start":{"line":572,"column":14},"end":{"line":574,"column":15}}],"line":572},"24":{"loc":{"start":{"line":591,"column":13},"end":{"line":601,"column":19}},"type":"binary-expr","locations":[{"start":{"line":591,"column":13},"end":{"line":591,"column":49}},{"start":{"line":592,"column":14},"end":{"line":601,"column":19}}],"line":591},"25":{"loc":{"start":{"line":642,"column":4},"end":{"line":646,"column":5}},"type":"if","locations":[{"start":{"line":642,"column":4},"end":{"line":646,"column":5}},{"start":{"line":642,"column":4},"end":{"line":646,"column":5}}],"line":642},"26":{"loc":{"start":{"line":642,"column":8},"end":{"line":642,"column":41}},"type":"binary-expr","locations":[{"start":{"line":642,"column":8},"end":{"line":642,"column":22}},{"start":{"line":642,"column":26},"end":{"line":642,"column":41}}],"line":642},"27":{"loc":{"start":{"line":644,"column":11},"end":{"line":646,"column":5}},"type":"if","locations":[{"start":{"line":644,"column":11},"end":{"line":646,"column":5}},{"start":{"line":644,"column":11},"end":{"line":646,"column":5}}],"line":644},"28":{"loc":{"start":{"line":644,"column":15},"end":{"line":644,"column":49}},"type":"binary-expr","locations":[{"start":{"line":644,"column":15},"end":{"line":644,"column":29}},{"start":{"line":644,"column":33},"end":{"line":644,"column":49}}],"line":644},"29":{"loc":{"start":{"line":652,"column":4},"end":{"line":658,"column":5}},"type":"switch","locations":[{"start":{"line":653,"column":6},"end":{"line":654,"column":58}},{"start":{"line":655,"column":6},"end":{"line":655,"column":21}},{"start":{"line":656,"column":6},"end":{"line":657,"column":56}}],"line":652}},"s":{"0":1,"1":1,"2":1,"3":2,"4":2,"5":2,"6":2,"7":2,"8":2,"9":2,"10":2,"11":2,"12":2,"13":2,"14":2,"15":2,"16":2,"17":2,"18":2,"19":2,"20":2,"21":2,"22":2,"23":2,"24":2,"25":2,"26":2,"27":2,"28":2,"29":2,"30":2,"31":2,"32":2,"33":2,"34":2,"35":2,"36":2,"37":2,"38":2,"39":2,"40":0,"41":0,"42":0,"43":0,"44":0,"45":0,"46":0,"47":0,"48":0,"49":0,"50":0,"51":0,"52":0,"53":0,"54":0,"55":0,"56":0,"57":0,"58":0,"59":0,"60":0,"61":0,"62":0,"63":0,"64":0,"65":0,"66":0,"67":0,"68":0,"69":0,"70":0,"71":0,"72":0,"73":0,"74":0,"75":0,"76":0,"77":0,"78":0,"79":0,"80":0,"81":0,"82":0,"83":0,"84":0,"85":0,"86":0,"87":0,"88":0,"89":0,"90":0,"91":0,"92":0,"93":0,"94":0,"95":0,"96":0,"97":0,"98":0,"99":0,"100":0,"101":0,"102":0,"103":0,"104":0,"105":0,"106":2,"107":0,"108":0,"109":0,"110":0,"111":0,"112":0,"113":0,"114":0,"115":0,"116":0,"117":0,"118":0,"119":0,"120":0,"121":2,"122":2,"123":2,"124":0,"125":2,"126":0,"127":2,"128":2,"129":0,"130":2,"131":2,"132":2,"133":1,"134":1,"135":1,"136":0,"137":0,"138":1},"f":{"0":2,"1":2,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0,"27":0,"28":0,"29":2,"30":0,"31":0,"32":0,"33":0,"34":0,"35":0,"36":0,"37":0,"38":2,"39":2,"40":2,"41":1,"42":0,"43":0},"b":{"0":[1,0],"1":[0,0],"2":[0,0],"3":[0,0],"4":[0,0],"5":[0,0],"6":[0,0],"7":[0,0],"8":[0,0],"9":[0,0],"10":[0,0],"11":[0,0],"12":[0,0],"13":[2,0,0,0],"14":[2,2,2],"15":[2,2],"16":[2,2],"17":[2,2],"18":[2,0,0,0],"19":[2,0],"20":[0,0],"21":[0,0],"22":[0,0],"23":[0,0],"24":[0,0],"25":[0,2],"26":[2,0],"27":[0,2],"28":[2,0],"29":[0,2,2]},"_coverageSchema":"43e27e138ebf9cfc5966b082cf9a028302ed4184","hash":"60513759a57d451d7ff4faa2b9617b8ea3ce1d6a"} +,"/home/lalis/git/p5.js-web-editor/client/modules/IDE/actions/console.js": {"path":"/home/lalis/git/p5.js-web-editor/client/modules/IDE/actions/console.js","statementMap":{"0":{"start":{"line":4,"column":2},"end":{"line":6,"column":4}},"1":{"start":{"line":10,"column":2},"end":{"line":13,"column":4}}},"fnMap":{"0":{"name":"clearConsole","decl":{"start":{"line":3,"column":16},"end":{"line":3,"column":28}},"loc":{"start":{"line":3,"column":31},"end":{"line":7,"column":1}},"line":3},"1":{"name":"dispatchConsoleEvent","decl":{"start":{"line":9,"column":16},"end":{"line":9,"column":36}},"loc":{"start":{"line":9,"column":47},"end":{"line":14,"column":1}},"line":9}},"branchMap":{},"s":{"0":0,"1":0},"f":{"0":0,"1":0},"b":{},"_coverageSchema":"43e27e138ebf9cfc5966b082cf9a028302ed4184","hash":"ad4e4fb651f40d96f866e7bf20346b0c1b6fa622"} +,"/home/lalis/git/p5.js-web-editor/client/modules/IDE/actions/files.js": {"path":"/home/lalis/git/p5.js-web-editor/client/modules/IDE/actions/files.js","statementMap":{"0":{"start":{"line":9,"column":18},"end":{"line":9,"column":75}},"1":{"start":{"line":10,"column":17},"end":{"line":10,"column":38}},"2":{"start":{"line":13,"column":19},"end":{"line":13,"column":44}},"3":{"start":{"line":14,"column":2},"end":{"line":14,"column":48}},"4":{"start":{"line":14,"column":23},"end":{"line":14,"column":48}},"5":{"start":{"line":15,"column":2},"end":{"line":15,"column":81}},"6":{"start":{"line":19,"column":23},"end":{"line":20,"column":77}},"7":{"start":{"line":19,"column":42},"end":{"line":19,"column":62}},"8":{"start":{"line":20,"column":33},"end":{"line":20,"column":76}},"9":{"start":{"line":20,"column":52},"end":{"line":20,"column":75}},"10":{"start":{"line":21,"column":17},"end":{"line":21,"column":21}},"11":{"start":{"line":22,"column":14},"end":{"line":22,"column":15}},"12":{"start":{"line":23,"column":21},"end":{"line":23,"column":66}},"13":{"start":{"line":23,"column":47},"end":{"line":23,"column":65}},"14":{"start":{"line":25,"column":2},"end":{"line":29,"column":3}},"15":{"start":{"line":26,"column":4},"end":{"line":26,"column":51}},"16":{"start":{"line":27,"column":4},"end":{"line":27,"column":15}},"17":{"start":{"line":28,"column":4},"end":{"line":28,"column":71}},"18":{"start":{"line":28,"column":47},"end":{"line":28,"column":69}},"19":{"start":{"line":30,"column":2},"end":{"line":30,"column":18}},"20":{"start":{"line":34,"column":2},"end":{"line":38,"column":4}},"21":{"start":{"line":42,"column":2},"end":{"line":91,"column":4}},"22":{"start":{"line":43,"column":18},"end":{"line":43,"column":28}},"23":{"start":{"line":44,"column":25},"end":{"line":44,"column":34}},"24":{"start":{"line":45,"column":4},"end":{"line":90,"column":5}},"25":{"start":{"line":46,"column":25},"end":{"line":52,"column":7}},"26":{"start":{"line":53,"column":6},"end":{"line":71,"column":12}},"27":{"start":{"line":55,"column":10},"end":{"line":59,"column":13}},"28":{"start":{"line":60,"column":10},"end":{"line":60,"column":73}},"29":{"start":{"line":61,"column":10},"end":{"line":61,"column":40}},"30":{"start":{"line":62,"column":10},"end":{"line":62,"column":38}},"31":{"start":{"line":66,"column":10},"end":{"line":66,"column":44}},"32":{"start":{"line":68,"column":27},"end":{"line":71,"column":10}},"33":{"start":{"line":73,"column":17},"end":{"line":73,"column":41}},"34":{"start":{"line":74,"column":6},"end":{"line":83,"column":9}},"35":{"start":{"line":84,"column":6},"end":{"line":84,"column":34}},"36":{"start":{"line":88,"column":6},"end":{"line":88,"column":40}},"37":{"start":{"line":89,"column":6},"end":{"line":89,"column":36}},"38":{"start":{"line":95,"column":2},"end":{"line":135,"column":4}},"39":{"start":{"line":96,"column":18},"end":{"line":96,"column":28}},"40":{"start":{"line":97,"column":25},"end":{"line":97,"column":34}},"41":{"start":{"line":98,"column":4},"end":{"line":134,"column":5}},"42":{"start":{"line":99,"column":25},"end":{"line":105,"column":7}},"43":{"start":{"line":106,"column":6},"end":{"line":119,"column":12}},"44":{"start":{"line":108,"column":10},"end":{"line":112,"column":13}},"45":{"start":{"line":113,"column":10},"end":{"line":113,"column":73}},"46":{"start":{"line":114,"column":10},"end":{"line":114,"column":42}},"47":{"start":{"line":116,"column":27},"end":{"line":119,"column":10}},"48":{"start":{"line":121,"column":17},"end":{"line":121,"column":41}},"49":{"start":{"line":122,"column":6},"end":{"line":132,"column":9}},"50":{"start":{"line":133,"column":6},"end":{"line":133,"column":38}},"51":{"start":{"line":139,"column":2},"end":{"line":146,"column":4}},"52":{"start":{"line":140,"column":4},"end":{"line":140,"column":38}},"53":{"start":{"line":141,"column":4},"end":{"line":145,"column":7}},"54":{"start":{"line":150,"column":2},"end":{"line":179,"column":4}},"55":{"start":{"line":151,"column":18},"end":{"line":151,"column":28}},"56":{"start":{"line":152,"column":4},"end":{"line":178,"column":5}},"57":{"start":{"line":153,"column":27},"end":{"line":157,"column":7}},"58":{"start":{"line":158,"column":6},"end":{"line":171,"column":11}},"59":{"start":{"line":160,"column":10},"end":{"line":164,"column":13}},"60":{"start":{"line":167,"column":10},"end":{"line":170,"column":13}},"61":{"start":{"line":173,"column":6},"end":{"line":177,"column":9}},"62":{"start":{"line":183,"column":2},"end":{"line":186,"column":4}},"63":{"start":{"line":190,"column":2},"end":{"line":193,"column":4}},"64":{"start":{"line":197,"column":2},"end":{"line":201,"column":4}},"65":{"start":{"line":205,"column":2},"end":{"line":207,"column":3}},"66":{"start":{"line":206,"column":4},"end":{"line":206,"column":43}},"67":{"start":{"line":209,"column":19},"end":{"line":209,"column":78}},"68":{"start":{"line":210,"column":18},"end":{"line":210,"column":52}},"69":{"start":{"line":211,"column":2},"end":{"line":211,"column":17}}},"fnMap":{"0":{"name":"appendToFilename","decl":{"start":{"line":12,"column":9},"end":{"line":12,"column":25}},"loc":{"start":{"line":12,"column":44},"end":{"line":16,"column":1}},"line":12},"1":{"name":"createUniqueName","decl":{"start":{"line":18,"column":9},"end":{"line":18,"column":25}},"loc":{"start":{"line":18,"column":49},"end":{"line":31,"column":1}},"line":18},"2":{"name":"(anonymous_2)","decl":{"start":{"line":19,"column":34},"end":{"line":19,"column":35}},"loc":{"start":{"line":19,"column":42},"end":{"line":19,"column":62}},"line":19},"3":{"name":"(anonymous_3)","decl":{"start":{"line":20,"column":18},"end":{"line":20,"column":19}},"loc":{"start":{"line":20,"column":33},"end":{"line":20,"column":76}},"line":20},"4":{"name":"(anonymous_4)","decl":{"start":{"line":20,"column":44},"end":{"line":20,"column":45}},"loc":{"start":{"line":20,"column":52},"end":{"line":20,"column":75}},"line":20},"5":{"name":"(anonymous_5)","decl":{"start":{"line":23,"column":39},"end":{"line":23,"column":40}},"loc":{"start":{"line":23,"column":47},"end":{"line":23,"column":65}},"line":23},"6":{"name":"(anonymous_6)","decl":{"start":{"line":28,"column":37},"end":{"line":28,"column":38}},"loc":{"start":{"line":28,"column":47},"end":{"line":28,"column":69}},"line":28},"7":{"name":"updateFileContent","decl":{"start":{"line":33,"column":16},"end":{"line":33,"column":33}},"loc":{"start":{"line":33,"column":47},"end":{"line":39,"column":1}},"line":33},"8":{"name":"createFile","decl":{"start":{"line":41,"column":16},"end":{"line":41,"column":26}},"loc":{"start":{"line":41,"column":38},"end":{"line":92,"column":1}},"line":41},"9":{"name":"(anonymous_9)","decl":{"start":{"line":42,"column":9},"end":{"line":42,"column":10}},"loc":{"start":{"line":42,"column":33},"end":{"line":91,"column":3}},"line":42},"10":{"name":"(anonymous_10)","decl":{"start":{"line":54,"column":14},"end":{"line":54,"column":15}},"loc":{"start":{"line":54,"column":28},"end":{"line":67,"column":9}},"line":54},"11":{"name":"(anonymous_11)","decl":{"start":{"line":68,"column":15},"end":{"line":68,"column":16}},"loc":{"start":{"line":68,"column":27},"end":{"line":71,"column":10}},"line":68},"12":{"name":"createFolder","decl":{"start":{"line":94,"column":16},"end":{"line":94,"column":28}},"loc":{"start":{"line":94,"column":40},"end":{"line":136,"column":1}},"line":94},"13":{"name":"(anonymous_13)","decl":{"start":{"line":95,"column":9},"end":{"line":95,"column":10}},"loc":{"start":{"line":95,"column":33},"end":{"line":135,"column":3}},"line":95},"14":{"name":"(anonymous_14)","decl":{"start":{"line":107,"column":14},"end":{"line":107,"column":15}},"loc":{"start":{"line":107,"column":28},"end":{"line":115,"column":9}},"line":107},"15":{"name":"(anonymous_15)","decl":{"start":{"line":116,"column":15},"end":{"line":116,"column":16}},"loc":{"start":{"line":116,"column":27},"end":{"line":119,"column":10}},"line":116},"16":{"name":"updateFileName","decl":{"start":{"line":138,"column":16},"end":{"line":138,"column":30}},"loc":{"start":{"line":138,"column":41},"end":{"line":147,"column":1}},"line":138},"17":{"name":"(anonymous_17)","decl":{"start":{"line":139,"column":9},"end":{"line":139,"column":10}},"loc":{"start":{"line":139,"column":23},"end":{"line":146,"column":3}},"line":139},"18":{"name":"deleteFile","decl":{"start":{"line":149,"column":16},"end":{"line":149,"column":26}},"loc":{"start":{"line":149,"column":41},"end":{"line":180,"column":1}},"line":149},"19":{"name":"(anonymous_19)","decl":{"start":{"line":150,"column":9},"end":{"line":150,"column":10}},"loc":{"start":{"line":150,"column":33},"end":{"line":179,"column":3}},"line":150},"20":{"name":"(anonymous_20)","decl":{"start":{"line":159,"column":14},"end":{"line":159,"column":15}},"loc":{"start":{"line":159,"column":20},"end":{"line":165,"column":9}},"line":159},"21":{"name":"(anonymous_21)","decl":{"start":{"line":166,"column":15},"end":{"line":166,"column":16}},"loc":{"start":{"line":166,"column":29},"end":{"line":171,"column":9}},"line":166},"22":{"name":"showFolderChildren","decl":{"start":{"line":182,"column":16},"end":{"line":182,"column":34}},"loc":{"start":{"line":182,"column":39},"end":{"line":187,"column":1}},"line":182},"23":{"name":"hideFolderChildren","decl":{"start":{"line":189,"column":16},"end":{"line":189,"column":34}},"loc":{"start":{"line":189,"column":39},"end":{"line":194,"column":1}},"line":189},"24":{"name":"setBlobUrl","decl":{"start":{"line":196,"column":16},"end":{"line":196,"column":26}},"loc":{"start":{"line":196,"column":42},"end":{"line":202,"column":1}},"line":196},"25":{"name":"getBlobUrl","decl":{"start":{"line":204,"column":16},"end":{"line":204,"column":26}},"loc":{"start":{"line":204,"column":33},"end":{"line":212,"column":1}},"line":204}},"branchMap":{"0":{"loc":{"start":{"line":9,"column":19},"end":{"line":9,"column":66}},"type":"cond-expr","locations":[{"start":{"line":9,"column":51},"end":{"line":9,"column":57}},{"start":{"line":9,"column":60},"end":{"line":9,"column":66}}],"line":9},"1":{"loc":{"start":{"line":14,"column":2},"end":{"line":14,"column":48}},"type":"if","locations":[{"start":{"line":14,"column":2},"end":{"line":14,"column":48}},{"start":{"line":14,"column":2},"end":{"line":14,"column":48}}],"line":14},"2":{"loc":{"start":{"line":45,"column":4},"end":{"line":90,"column":5}},"type":"if","locations":[{"start":{"line":45,"column":4},"end":{"line":90,"column":5}},{"start":{"line":45,"column":4},"end":{"line":90,"column":5}}],"line":45},"3":{"loc":{"start":{"line":49,"column":17},"end":{"line":49,"column":40}},"type":"binary-expr","locations":[{"start":{"line":49,"column":17},"end":{"line":49,"column":34}},{"start":{"line":49,"column":38},"end":{"line":49,"column":40}}],"line":49},"4":{"loc":{"start":{"line":80,"column":17},"end":{"line":80,"column":40}},"type":"binary-expr","locations":[{"start":{"line":80,"column":17},"end":{"line":80,"column":34}},{"start":{"line":80,"column":38},"end":{"line":80,"column":40}}],"line":80},"5":{"loc":{"start":{"line":98,"column":4},"end":{"line":134,"column":5}},"type":"if","locations":[{"start":{"line":98,"column":4},"end":{"line":134,"column":5}},{"start":{"line":98,"column":4},"end":{"line":134,"column":5}}],"line":98},"6":{"loc":{"start":{"line":152,"column":4},"end":{"line":178,"column":5}},"type":"if","locations":[{"start":{"line":152,"column":4},"end":{"line":178,"column":5}},{"start":{"line":152,"column":4},"end":{"line":178,"column":5}}],"line":152},"7":{"loc":{"start":{"line":205,"column":2},"end":{"line":207,"column":3}},"type":"if","locations":[{"start":{"line":205,"column":2},"end":{"line":207,"column":3}},{"start":{"line":205,"column":2},"end":{"line":207,"column":3}}],"line":205}},"s":{"0":1,"1":1,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0,"27":0,"28":0,"29":0,"30":0,"31":0,"32":0,"33":0,"34":0,"35":0,"36":0,"37":0,"38":0,"39":0,"40":0,"41":0,"42":0,"43":0,"44":0,"45":0,"46":0,"47":0,"48":0,"49":0,"50":0,"51":0,"52":0,"53":0,"54":0,"55":0,"56":0,"57":0,"58":0,"59":0,"60":0,"61":0,"62":0,"63":0,"64":0,"65":0,"66":0,"67":0,"68":0,"69":0},"f":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0},"b":{"0":[1,0],"1":[0,0],"2":[0,0],"3":[0,0],"4":[0,0],"5":[0,0],"6":[0,0],"7":[0,0]},"_coverageSchema":"43e27e138ebf9cfc5966b082cf9a028302ed4184","hash":"ef11bdaaeee59832a5c8d3af16086e00cbaa407b"} +,"/home/lalis/git/p5.js-web-editor/client/modules/IDE/actions/ide.js": {"path":"/home/lalis/git/p5.js-web-editor/client/modules/IDE/actions/ide.js","statementMap":{"0":{"start":{"line":5,"column":2},"end":{"line":7,"column":4}},"1":{"start":{"line":11,"column":2},"end":{"line":13,"column":4}},"2":{"start":{"line":17,"column":2},"end":{"line":19,"column":4}},"3":{"start":{"line":23,"column":2},"end":{"line":26,"column":4}},"4":{"start":{"line":24,"column":4},"end":{"line":24,"column":34}},"5":{"start":{"line":25,"column":4},"end":{"line":25,"column":35}},"6":{"start":{"line":30,"column":2},"end":{"line":32,"column":4}},"7":{"start":{"line":36,"column":2},"end":{"line":38,"column":4}},"8":{"start":{"line":42,"column":2},"end":{"line":44,"column":4}},"9":{"start":{"line":48,"column":2},"end":{"line":51,"column":4}},"10":{"start":{"line":55,"column":2},"end":{"line":62,"column":4}},"11":{"start":{"line":56,"column":18},"end":{"line":56,"column":28}},"12":{"start":{"line":57,"column":18},"end":{"line":57,"column":93}},"13":{"start":{"line":57,"column":43},"end":{"line":57,"column":89}},"14":{"start":{"line":58,"column":4},"end":{"line":61,"column":7}},"15":{"start":{"line":66,"column":2},"end":{"line":69,"column":4}},"16":{"start":{"line":73,"column":2},"end":{"line":75,"column":4}},"17":{"start":{"line":79,"column":2},"end":{"line":82,"column":4}},"18":{"start":{"line":86,"column":2},"end":{"line":88,"column":4}},"19":{"start":{"line":92,"column":2},"end":{"line":94,"column":4}},"20":{"start":{"line":98,"column":2},"end":{"line":100,"column":4}},"21":{"start":{"line":104,"column":2},"end":{"line":106,"column":4}},"22":{"start":{"line":110,"column":2},"end":{"line":112,"column":4}},"23":{"start":{"line":116,"column":2},"end":{"line":118,"column":4}},"24":{"start":{"line":122,"column":2},"end":{"line":124,"column":4}},"25":{"start":{"line":128,"column":2},"end":{"line":130,"column":4}},"26":{"start":{"line":134,"column":2},"end":{"line":136,"column":4}},"27":{"start":{"line":140,"column":2},"end":{"line":143,"column":4}},"28":{"start":{"line":147,"column":2},"end":{"line":149,"column":4}},"29":{"start":{"line":153,"column":2},"end":{"line":163,"column":4}},"30":{"start":{"line":154,"column":30},"end":{"line":154,"column":40}},"31":{"start":{"line":155,"column":4},"end":{"line":162,"column":7}},"32":{"start":{"line":167,"column":2},"end":{"line":169,"column":4}},"33":{"start":{"line":173,"column":2},"end":{"line":175,"column":4}},"34":{"start":{"line":179,"column":2},"end":{"line":181,"column":4}},"35":{"start":{"line":185,"column":2},"end":{"line":187,"column":4}},"36":{"start":{"line":191,"column":2},"end":{"line":193,"column":4}},"37":{"start":{"line":197,"column":2},"end":{"line":200,"column":4}},"38":{"start":{"line":204,"column":2},"end":{"line":207,"column":4}},"39":{"start":{"line":211,"column":2},"end":{"line":213,"column":4}},"40":{"start":{"line":217,"column":2},"end":{"line":219,"column":4}},"41":{"start":{"line":223,"column":2},"end":{"line":225,"column":4}},"42":{"start":{"line":229,"column":2},"end":{"line":232,"column":4}},"43":{"start":{"line":236,"column":2},"end":{"line":239,"column":4}},"44":{"start":{"line":243,"column":2},"end":{"line":245,"column":4}},"45":{"start":{"line":249,"column":2},"end":{"line":251,"column":4}},"46":{"start":{"line":255,"column":2},"end":{"line":257,"column":4}},"47":{"start":{"line":261,"column":2},"end":{"line":264,"column":4}},"48":{"start":{"line":262,"column":4},"end":{"line":262,"column":29}},"49":{"start":{"line":263,"column":4},"end":{"line":263,"column":38}},"50":{"start":{"line":268,"column":2},"end":{"line":272,"column":4}},"51":{"start":{"line":269,"column":4},"end":{"line":269,"column":29}},"52":{"start":{"line":270,"column":4},"end":{"line":270,"column":38}},"53":{"start":{"line":271,"column":4},"end":{"line":271,"column":38}},"54":{"start":{"line":276,"column":2},"end":{"line":279,"column":4}},"55":{"start":{"line":277,"column":4},"end":{"line":277,"column":37}},"56":{"start":{"line":278,"column":4},"end":{"line":278,"column":33}}},"fnMap":{"0":{"name":"startVisualSketch","decl":{"start":{"line":4,"column":16},"end":{"line":4,"column":33}},"loc":{"start":{"line":4,"column":36},"end":{"line":8,"column":1}},"line":4},"1":{"name":"stopVisualSketch","decl":{"start":{"line":10,"column":16},"end":{"line":10,"column":32}},"loc":{"start":{"line":10,"column":35},"end":{"line":14,"column":1}},"line":10},"2":{"name":"startRefreshSketch","decl":{"start":{"line":16,"column":16},"end":{"line":16,"column":34}},"loc":{"start":{"line":16,"column":37},"end":{"line":20,"column":1}},"line":16},"3":{"name":"startSketchAndRefresh","decl":{"start":{"line":22,"column":16},"end":{"line":22,"column":37}},"loc":{"start":{"line":22,"column":40},"end":{"line":27,"column":1}},"line":22},"4":{"name":"(anonymous_4)","decl":{"start":{"line":23,"column":9},"end":{"line":23,"column":10}},"loc":{"start":{"line":23,"column":23},"end":{"line":26,"column":3}},"line":23},"5":{"name":"endSketchRefresh","decl":{"start":{"line":29,"column":16},"end":{"line":29,"column":32}},"loc":{"start":{"line":29,"column":35},"end":{"line":33,"column":1}},"line":29},"6":{"name":"startAccessibleOutput","decl":{"start":{"line":35,"column":16},"end":{"line":35,"column":37}},"loc":{"start":{"line":35,"column":40},"end":{"line":39,"column":1}},"line":35},"7":{"name":"stopAccessibleOutput","decl":{"start":{"line":41,"column":16},"end":{"line":41,"column":36}},"loc":{"start":{"line":41,"column":39},"end":{"line":45,"column":1}},"line":41},"8":{"name":"setSelectedFile","decl":{"start":{"line":47,"column":16},"end":{"line":47,"column":31}},"loc":{"start":{"line":47,"column":40},"end":{"line":52,"column":1}},"line":47},"9":{"name":"resetSelectedFile","decl":{"start":{"line":54,"column":16},"end":{"line":54,"column":33}},"loc":{"start":{"line":54,"column":46},"end":{"line":63,"column":1}},"line":54},"10":{"name":"(anonymous_10)","decl":{"start":{"line":55,"column":9},"end":{"line":55,"column":10}},"loc":{"start":{"line":55,"column":33},"end":{"line":62,"column":3}},"line":55},"11":{"name":"(anonymous_11)","decl":{"start":{"line":57,"column":35},"end":{"line":57,"column":36}},"loc":{"start":{"line":57,"column":43},"end":{"line":57,"column":89}},"line":57},"12":{"name":"newFile","decl":{"start":{"line":65,"column":16},"end":{"line":65,"column":23}},"loc":{"start":{"line":65,"column":34},"end":{"line":70,"column":1}},"line":65},"13":{"name":"closeNewFileModal","decl":{"start":{"line":72,"column":16},"end":{"line":72,"column":33}},"loc":{"start":{"line":72,"column":36},"end":{"line":76,"column":1}},"line":72},"14":{"name":"openUploadFileModal","decl":{"start":{"line":78,"column":16},"end":{"line":78,"column":35}},"loc":{"start":{"line":78,"column":46},"end":{"line":83,"column":1}},"line":78},"15":{"name":"closeUploadFileModal","decl":{"start":{"line":85,"column":16},"end":{"line":85,"column":36}},"loc":{"start":{"line":85,"column":39},"end":{"line":89,"column":1}},"line":85},"16":{"name":"expandSidebar","decl":{"start":{"line":91,"column":16},"end":{"line":91,"column":29}},"loc":{"start":{"line":91,"column":32},"end":{"line":95,"column":1}},"line":91},"17":{"name":"collapseSidebar","decl":{"start":{"line":97,"column":16},"end":{"line":97,"column":31}},"loc":{"start":{"line":97,"column":34},"end":{"line":101,"column":1}},"line":97},"18":{"name":"expandConsole","decl":{"start":{"line":103,"column":16},"end":{"line":103,"column":29}},"loc":{"start":{"line":103,"column":32},"end":{"line":107,"column":1}},"line":103},"19":{"name":"collapseConsole","decl":{"start":{"line":109,"column":16},"end":{"line":109,"column":31}},"loc":{"start":{"line":109,"column":34},"end":{"line":113,"column":1}},"line":109},"20":{"name":"openPreferences","decl":{"start":{"line":115,"column":16},"end":{"line":115,"column":31}},"loc":{"start":{"line":115,"column":34},"end":{"line":119,"column":1}},"line":115},"21":{"name":"closePreferences","decl":{"start":{"line":121,"column":16},"end":{"line":121,"column":32}},"loc":{"start":{"line":121,"column":35},"end":{"line":125,"column":1}},"line":121},"22":{"name":"openProjectOptions","decl":{"start":{"line":127,"column":16},"end":{"line":127,"column":34}},"loc":{"start":{"line":127,"column":37},"end":{"line":131,"column":1}},"line":127},"23":{"name":"closeProjectOptions","decl":{"start":{"line":133,"column":16},"end":{"line":133,"column":35}},"loc":{"start":{"line":133,"column":38},"end":{"line":137,"column":1}},"line":133},"24":{"name":"newFolder","decl":{"start":{"line":139,"column":16},"end":{"line":139,"column":25}},"loc":{"start":{"line":139,"column":36},"end":{"line":144,"column":1}},"line":139},"25":{"name":"closeNewFolderModal","decl":{"start":{"line":146,"column":16},"end":{"line":146,"column":35}},"loc":{"start":{"line":146,"column":38},"end":{"line":150,"column":1}},"line":146},"26":{"name":"showShareModal","decl":{"start":{"line":152,"column":16},"end":{"line":152,"column":30}},"loc":{"start":{"line":152,"column":70},"end":{"line":164,"column":1}},"line":152},"27":{"name":"(anonymous_27)","decl":{"start":{"line":153,"column":9},"end":{"line":153,"column":10}},"loc":{"start":{"line":153,"column":33},"end":{"line":163,"column":3}},"line":153},"28":{"name":"closeShareModal","decl":{"start":{"line":166,"column":16},"end":{"line":166,"column":31}},"loc":{"start":{"line":166,"column":34},"end":{"line":170,"column":1}},"line":166},"29":{"name":"showEditorOptions","decl":{"start":{"line":172,"column":16},"end":{"line":172,"column":33}},"loc":{"start":{"line":172,"column":36},"end":{"line":176,"column":1}},"line":172},"30":{"name":"closeEditorOptions","decl":{"start":{"line":178,"column":16},"end":{"line":178,"column":34}},"loc":{"start":{"line":178,"column":37},"end":{"line":182,"column":1}},"line":178},"31":{"name":"showKeyboardShortcutModal","decl":{"start":{"line":184,"column":16},"end":{"line":184,"column":41}},"loc":{"start":{"line":184,"column":44},"end":{"line":188,"column":1}},"line":184},"32":{"name":"closeKeyboardShortcutModal","decl":{"start":{"line":190,"column":16},"end":{"line":190,"column":42}},"loc":{"start":{"line":190,"column":45},"end":{"line":194,"column":1}},"line":190},"33":{"name":"setUnsavedChanges","decl":{"start":{"line":196,"column":16},"end":{"line":196,"column":33}},"loc":{"start":{"line":196,"column":41},"end":{"line":201,"column":1}},"line":196},"34":{"name":"detectInfiniteLoops","decl":{"start":{"line":203,"column":16},"end":{"line":203,"column":35}},"loc":{"start":{"line":203,"column":45},"end":{"line":208,"column":1}},"line":203},"35":{"name":"resetInfiniteLoops","decl":{"start":{"line":210,"column":16},"end":{"line":210,"column":34}},"loc":{"start":{"line":210,"column":37},"end":{"line":214,"column":1}},"line":210},"36":{"name":"justOpenedProject","decl":{"start":{"line":216,"column":16},"end":{"line":216,"column":33}},"loc":{"start":{"line":216,"column":36},"end":{"line":220,"column":1}},"line":216},"37":{"name":"resetJustOpenedProject","decl":{"start":{"line":222,"column":16},"end":{"line":222,"column":38}},"loc":{"start":{"line":222,"column":41},"end":{"line":226,"column":1}},"line":222},"38":{"name":"setPreviousPath","decl":{"start":{"line":228,"column":16},"end":{"line":228,"column":31}},"loc":{"start":{"line":228,"column":38},"end":{"line":233,"column":1}},"line":228},"39":{"name":"showErrorModal","decl":{"start":{"line":235,"column":16},"end":{"line":235,"column":30}},"loc":{"start":{"line":235,"column":42},"end":{"line":240,"column":1}},"line":235},"40":{"name":"hideErrorModal","decl":{"start":{"line":242,"column":16},"end":{"line":242,"column":30}},"loc":{"start":{"line":242,"column":33},"end":{"line":246,"column":1}},"line":242},"41":{"name":"hideRuntimeErrorWarning","decl":{"start":{"line":248,"column":16},"end":{"line":248,"column":39}},"loc":{"start":{"line":248,"column":42},"end":{"line":252,"column":1}},"line":248},"42":{"name":"showRuntimeErrorWarning","decl":{"start":{"line":254,"column":16},"end":{"line":254,"column":39}},"loc":{"start":{"line":254,"column":42},"end":{"line":258,"column":1}},"line":254},"43":{"name":"startSketch","decl":{"start":{"line":260,"column":16},"end":{"line":260,"column":27}},"loc":{"start":{"line":260,"column":30},"end":{"line":265,"column":1}},"line":260},"44":{"name":"(anonymous_44)","decl":{"start":{"line":261,"column":9},"end":{"line":261,"column":10}},"loc":{"start":{"line":261,"column":23},"end":{"line":264,"column":3}},"line":261},"45":{"name":"startAccessibleSketch","decl":{"start":{"line":267,"column":16},"end":{"line":267,"column":37}},"loc":{"start":{"line":267,"column":40},"end":{"line":273,"column":1}},"line":267},"46":{"name":"(anonymous_46)","decl":{"start":{"line":268,"column":9},"end":{"line":268,"column":10}},"loc":{"start":{"line":268,"column":23},"end":{"line":272,"column":3}},"line":268},"47":{"name":"stopSketch","decl":{"start":{"line":275,"column":16},"end":{"line":275,"column":26}},"loc":{"start":{"line":275,"column":29},"end":{"line":280,"column":1}},"line":275},"48":{"name":"(anonymous_48)","decl":{"start":{"line":276,"column":9},"end":{"line":276,"column":10}},"loc":{"start":{"line":276,"column":23},"end":{"line":279,"column":3}},"line":276}},"branchMap":{"0":{"loc":{"start":{"line":57,"column":43},"end":{"line":57,"column":89}},"type":"binary-expr","locations":[{"start":{"line":57,"column":43},"end":{"line":57,"column":63}},{"start":{"line":57,"column":67},"end":{"line":57,"column":89}}],"line":57},"1":{"loc":{"start":{"line":158,"column":29},"end":{"line":158,"column":52}},"type":"binary-expr","locations":[{"start":{"line":158,"column":29},"end":{"line":158,"column":38}},{"start":{"line":158,"column":42},"end":{"line":158,"column":52}}],"line":158},"2":{"loc":{"start":{"line":159,"column":31},"end":{"line":159,"column":58}},"type":"binary-expr","locations":[{"start":{"line":159,"column":31},"end":{"line":159,"column":42}},{"start":{"line":159,"column":46},"end":{"line":159,"column":58}}],"line":159},"3":{"loc":{"start":{"line":160,"column":35},"end":{"line":160,"column":65}},"type":"binary-expr","locations":[{"start":{"line":160,"column":35},"end":{"line":160,"column":48}},{"start":{"line":160,"column":52},"end":{"line":160,"column":65}}],"line":160}},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0,"27":0,"28":0,"29":0,"30":0,"31":0,"32":0,"33":0,"34":0,"35":0,"36":0,"37":0,"38":0,"39":0,"40":0,"41":0,"42":0,"43":0,"44":0,"45":0,"46":0,"47":0,"48":0,"49":0,"50":0,"51":0,"52":0,"53":0,"54":0,"55":0,"56":0},"f":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0,"27":0,"28":0,"29":0,"30":0,"31":0,"32":0,"33":0,"34":0,"35":0,"36":0,"37":0,"38":0,"39":0,"40":0,"41":0,"42":0,"43":0,"44":0,"45":0,"46":0,"47":0,"48":0},"b":{"0":[0,0],"1":[0,0],"2":[0,0],"3":[0,0]},"_coverageSchema":"43e27e138ebf9cfc5966b082cf9a028302ed4184","hash":"4d0e79d82ab84d2742ec6b1fe4bfbd34a3a4bb5a"} +,"/home/lalis/git/p5.js-web-editor/client/modules/IDE/actions/preferences.js": {"path":"/home/lalis/git/p5.js-web-editor/client/modules/IDE/actions/preferences.js","statementMap":{"0":{"start":{"line":4,"column":18},"end":{"line":4,"column":75}},"1":{"start":{"line":5,"column":17},"end":{"line":5,"column":38}},"2":{"start":{"line":8,"column":2},"end":{"line":14,"column":8}},"3":{"start":{"line":11,"column":23},"end":{"line":14,"column":6}},"4":{"start":{"line":18,"column":2},"end":{"line":32,"column":4}},"5":{"start":{"line":19,"column":4},"end":{"line":22,"column":7}},"6":{"start":{"line":23,"column":18},"end":{"line":23,"column":28}},"7":{"start":{"line":24,"column":4},"end":{"line":31,"column":5}},"8":{"start":{"line":25,"column":25},"end":{"line":29,"column":7}},"9":{"start":{"line":30,"column":6},"end":{"line":30,"column":46}},"10":{"start":{"line":36,"column":2},"end":{"line":50,"column":4}},"11":{"start":{"line":37,"column":4},"end":{"line":40,"column":7}},"12":{"start":{"line":41,"column":18},"end":{"line":41,"column":28}},"13":{"start":{"line":42,"column":4},"end":{"line":49,"column":5}},"14":{"start":{"line":43,"column":25},"end":{"line":47,"column":7}},"15":{"start":{"line":48,"column":6},"end":{"line":48,"column":46}},"16":{"start":{"line":54,"column":2},"end":{"line":68,"column":4}},"17":{"start":{"line":55,"column":4},"end":{"line":58,"column":7}},"18":{"start":{"line":59,"column":18},"end":{"line":59,"column":28}},"19":{"start":{"line":60,"column":4},"end":{"line":67,"column":5}},"20":{"start":{"line":61,"column":25},"end":{"line":65,"column":7}},"21":{"start":{"line":66,"column":6},"end":{"line":66,"column":46}},"22":{"start":{"line":72,"column":2},"end":{"line":86,"column":4}},"23":{"start":{"line":73,"column":4},"end":{"line":76,"column":7}},"24":{"start":{"line":77,"column":18},"end":{"line":77,"column":28}},"25":{"start":{"line":78,"column":4},"end":{"line":85,"column":5}},"26":{"start":{"line":79,"column":25},"end":{"line":83,"column":7}},"27":{"start":{"line":84,"column":6},"end":{"line":84,"column":46}},"28":{"start":{"line":90,"column":2},"end":{"line":104,"column":4}},"29":{"start":{"line":91,"column":4},"end":{"line":94,"column":7}},"30":{"start":{"line":95,"column":18},"end":{"line":95,"column":28}},"31":{"start":{"line":96,"column":4},"end":{"line":103,"column":5}},"32":{"start":{"line":97,"column":25},"end":{"line":101,"column":7}},"33":{"start":{"line":102,"column":6},"end":{"line":102,"column":46}},"34":{"start":{"line":108,"column":2},"end":{"line":122,"column":4}},"35":{"start":{"line":109,"column":4},"end":{"line":112,"column":7}},"36":{"start":{"line":113,"column":18},"end":{"line":113,"column":28}},"37":{"start":{"line":114,"column":4},"end":{"line":121,"column":5}},"38":{"start":{"line":115,"column":25},"end":{"line":119,"column":7}},"39":{"start":{"line":120,"column":6},"end":{"line":120,"column":46}},"40":{"start":{"line":126,"column":2},"end":{"line":140,"column":4}},"41":{"start":{"line":127,"column":4},"end":{"line":130,"column":7}},"42":{"start":{"line":131,"column":18},"end":{"line":131,"column":28}},"43":{"start":{"line":132,"column":4},"end":{"line":139,"column":5}},"44":{"start":{"line":133,"column":25},"end":{"line":137,"column":7}},"45":{"start":{"line":138,"column":6},"end":{"line":138,"column":46}},"46":{"start":{"line":144,"column":2},"end":{"line":158,"column":4}},"47":{"start":{"line":145,"column":4},"end":{"line":148,"column":7}},"48":{"start":{"line":149,"column":18},"end":{"line":149,"column":28}},"49":{"start":{"line":150,"column":4},"end":{"line":157,"column":5}},"50":{"start":{"line":151,"column":25},"end":{"line":155,"column":7}},"51":{"start":{"line":156,"column":6},"end":{"line":156,"column":46}},"52":{"start":{"line":166,"column":2},"end":{"line":180,"column":4}},"53":{"start":{"line":167,"column":4},"end":{"line":170,"column":7}},"54":{"start":{"line":171,"column":18},"end":{"line":171,"column":28}},"55":{"start":{"line":172,"column":4},"end":{"line":179,"column":5}},"56":{"start":{"line":173,"column":25},"end":{"line":177,"column":7}},"57":{"start":{"line":178,"column":6},"end":{"line":178,"column":46}},"58":{"start":{"line":188,"column":2},"end":{"line":202,"column":4}},"59":{"start":{"line":189,"column":4},"end":{"line":192,"column":7}},"60":{"start":{"line":193,"column":18},"end":{"line":193,"column":28}},"61":{"start":{"line":194,"column":4},"end":{"line":201,"column":5}},"62":{"start":{"line":195,"column":25},"end":{"line":199,"column":7}},"63":{"start":{"line":200,"column":6},"end":{"line":200,"column":46}},"64":{"start":{"line":206,"column":2},"end":{"line":210,"column":4}},"65":{"start":{"line":207,"column":4},"end":{"line":207,"column":35}},"66":{"start":{"line":208,"column":4},"end":{"line":208,"column":35}},"67":{"start":{"line":209,"column":4},"end":{"line":209,"column":36}}},"fnMap":{"0":{"name":"updatePreferences","decl":{"start":{"line":7,"column":9},"end":{"line":7,"column":26}},"loc":{"start":{"line":7,"column":49},"end":{"line":15,"column":1}},"line":7},"1":{"name":"(anonymous_1)","decl":{"start":{"line":9,"column":10},"end":{"line":9,"column":11}},"loc":{"start":{"line":9,"column":16},"end":{"line":10,"column":5}},"line":9},"2":{"name":"(anonymous_2)","decl":{"start":{"line":11,"column":11},"end":{"line":11,"column":12}},"loc":{"start":{"line":11,"column":23},"end":{"line":14,"column":6}},"line":11},"3":{"name":"setFontSize","decl":{"start":{"line":17,"column":16},"end":{"line":17,"column":27}},"loc":{"start":{"line":17,"column":35},"end":{"line":33,"column":1}},"line":17},"4":{"name":"(anonymous_4)","decl":{"start":{"line":18,"column":9},"end":{"line":18,"column":10}},"loc":{"start":{"line":18,"column":33},"end":{"line":32,"column":3}},"line":18},"5":{"name":"setLineNumbers","decl":{"start":{"line":35,"column":16},"end":{"line":35,"column":30}},"loc":{"start":{"line":35,"column":38},"end":{"line":51,"column":1}},"line":35},"6":{"name":"(anonymous_6)","decl":{"start":{"line":36,"column":9},"end":{"line":36,"column":10}},"loc":{"start":{"line":36,"column":33},"end":{"line":50,"column":3}},"line":36},"7":{"name":"setAutosave","decl":{"start":{"line":53,"column":16},"end":{"line":53,"column":27}},"loc":{"start":{"line":53,"column":35},"end":{"line":69,"column":1}},"line":53},"8":{"name":"(anonymous_8)","decl":{"start":{"line":54,"column":9},"end":{"line":54,"column":10}},"loc":{"start":{"line":54,"column":33},"end":{"line":68,"column":3}},"line":54},"9":{"name":"setLinewrap","decl":{"start":{"line":71,"column":16},"end":{"line":71,"column":27}},"loc":{"start":{"line":71,"column":35},"end":{"line":87,"column":1}},"line":71},"10":{"name":"(anonymous_10)","decl":{"start":{"line":72,"column":9},"end":{"line":72,"column":10}},"loc":{"start":{"line":72,"column":33},"end":{"line":86,"column":3}},"line":72},"11":{"name":"setLintWarning","decl":{"start":{"line":89,"column":16},"end":{"line":89,"column":30}},"loc":{"start":{"line":89,"column":38},"end":{"line":105,"column":1}},"line":89},"12":{"name":"(anonymous_12)","decl":{"start":{"line":90,"column":9},"end":{"line":90,"column":10}},"loc":{"start":{"line":90,"column":33},"end":{"line":104,"column":3}},"line":90},"13":{"name":"setTextOutput","decl":{"start":{"line":107,"column":16},"end":{"line":107,"column":29}},"loc":{"start":{"line":107,"column":37},"end":{"line":123,"column":1}},"line":107},"14":{"name":"(anonymous_14)","decl":{"start":{"line":108,"column":9},"end":{"line":108,"column":10}},"loc":{"start":{"line":108,"column":33},"end":{"line":122,"column":3}},"line":108},"15":{"name":"setGridOutput","decl":{"start":{"line":125,"column":16},"end":{"line":125,"column":29}},"loc":{"start":{"line":125,"column":37},"end":{"line":141,"column":1}},"line":125},"16":{"name":"(anonymous_16)","decl":{"start":{"line":126,"column":9},"end":{"line":126,"column":10}},"loc":{"start":{"line":126,"column":33},"end":{"line":140,"column":3}},"line":126},"17":{"name":"setSoundOutput","decl":{"start":{"line":143,"column":16},"end":{"line":143,"column":30}},"loc":{"start":{"line":143,"column":38},"end":{"line":159,"column":1}},"line":143},"18":{"name":"(anonymous_18)","decl":{"start":{"line":144,"column":9},"end":{"line":144,"column":10}},"loc":{"start":{"line":144,"column":33},"end":{"line":158,"column":3}},"line":144},"19":{"name":"setTheme","decl":{"start":{"line":161,"column":16},"end":{"line":161,"column":24}},"loc":{"start":{"line":161,"column":32},"end":{"line":181,"column":1}},"line":161},"20":{"name":"(anonymous_20)","decl":{"start":{"line":166,"column":9},"end":{"line":166,"column":10}},"loc":{"start":{"line":166,"column":33},"end":{"line":180,"column":3}},"line":166},"21":{"name":"setAutorefresh","decl":{"start":{"line":183,"column":16},"end":{"line":183,"column":30}},"loc":{"start":{"line":183,"column":38},"end":{"line":203,"column":1}},"line":183},"22":{"name":"(anonymous_22)","decl":{"start":{"line":188,"column":9},"end":{"line":188,"column":10}},"loc":{"start":{"line":188,"column":33},"end":{"line":202,"column":3}},"line":188},"23":{"name":"setAllAccessibleOutput","decl":{"start":{"line":205,"column":16},"end":{"line":205,"column":38}},"loc":{"start":{"line":205,"column":46},"end":{"line":211,"column":1}},"line":205},"24":{"name":"(anonymous_24)","decl":{"start":{"line":206,"column":9},"end":{"line":206,"column":10}},"loc":{"start":{"line":206,"column":23},"end":{"line":210,"column":3}},"line":206}},"branchMap":{"0":{"loc":{"start":{"line":4,"column":19},"end":{"line":4,"column":66}},"type":"cond-expr","locations":[{"start":{"line":4,"column":51},"end":{"line":4,"column":57}},{"start":{"line":4,"column":60},"end":{"line":4,"column":66}}],"line":4},"1":{"loc":{"start":{"line":24,"column":4},"end":{"line":31,"column":5}},"type":"if","locations":[{"start":{"line":24,"column":4},"end":{"line":31,"column":5}},{"start":{"line":24,"column":4},"end":{"line":31,"column":5}}],"line":24},"2":{"loc":{"start":{"line":42,"column":4},"end":{"line":49,"column":5}},"type":"if","locations":[{"start":{"line":42,"column":4},"end":{"line":49,"column":5}},{"start":{"line":42,"column":4},"end":{"line":49,"column":5}}],"line":42},"3":{"loc":{"start":{"line":60,"column":4},"end":{"line":67,"column":5}},"type":"if","locations":[{"start":{"line":60,"column":4},"end":{"line":67,"column":5}},{"start":{"line":60,"column":4},"end":{"line":67,"column":5}}],"line":60},"4":{"loc":{"start":{"line":78,"column":4},"end":{"line":85,"column":5}},"type":"if","locations":[{"start":{"line":78,"column":4},"end":{"line":85,"column":5}},{"start":{"line":78,"column":4},"end":{"line":85,"column":5}}],"line":78},"5":{"loc":{"start":{"line":96,"column":4},"end":{"line":103,"column":5}},"type":"if","locations":[{"start":{"line":96,"column":4},"end":{"line":103,"column":5}},{"start":{"line":96,"column":4},"end":{"line":103,"column":5}}],"line":96},"6":{"loc":{"start":{"line":114,"column":4},"end":{"line":121,"column":5}},"type":"if","locations":[{"start":{"line":114,"column":4},"end":{"line":121,"column":5}},{"start":{"line":114,"column":4},"end":{"line":121,"column":5}}],"line":114},"7":{"loc":{"start":{"line":132,"column":4},"end":{"line":139,"column":5}},"type":"if","locations":[{"start":{"line":132,"column":4},"end":{"line":139,"column":5}},{"start":{"line":132,"column":4},"end":{"line":139,"column":5}}],"line":132},"8":{"loc":{"start":{"line":150,"column":4},"end":{"line":157,"column":5}},"type":"if","locations":[{"start":{"line":150,"column":4},"end":{"line":157,"column":5}},{"start":{"line":150,"column":4},"end":{"line":157,"column":5}}],"line":150},"9":{"loc":{"start":{"line":172,"column":4},"end":{"line":179,"column":5}},"type":"if","locations":[{"start":{"line":172,"column":4},"end":{"line":179,"column":5}},{"start":{"line":172,"column":4},"end":{"line":179,"column":5}}],"line":172},"10":{"loc":{"start":{"line":194,"column":4},"end":{"line":201,"column":5}},"type":"if","locations":[{"start":{"line":194,"column":4},"end":{"line":201,"column":5}},{"start":{"line":194,"column":4},"end":{"line":201,"column":5}}],"line":194}},"s":{"0":1,"1":1,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0,"27":0,"28":0,"29":0,"30":0,"31":0,"32":0,"33":0,"34":0,"35":0,"36":0,"37":0,"38":0,"39":0,"40":0,"41":0,"42":0,"43":0,"44":0,"45":0,"46":0,"47":0,"48":0,"49":0,"50":0,"51":0,"52":0,"53":0,"54":0,"55":0,"56":0,"57":0,"58":0,"59":0,"60":0,"61":0,"62":0,"63":0,"64":0,"65":0,"66":0,"67":0},"f":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0},"b":{"0":[1,0],"1":[0,0],"2":[0,0],"3":[0,0],"4":[0,0],"5":[0,0],"6":[0,0],"7":[0,0],"8":[0,0],"9":[0,0],"10":[0,0]},"_coverageSchema":"43e27e138ebf9cfc5966b082cf9a028302ed4184","hash":"a0a575d85c243f09f09c4968dd481470b7c95a01"} +,"/home/lalis/git/p5.js-web-editor/client/modules/IDE/actions/project.js": {"path":"/home/lalis/git/p5.js-web-editor/client/modules/IDE/actions/project.js","statementMap":{"0":{"start":{"line":17,"column":18},"end":{"line":17,"column":75}},"1":{"start":{"line":18,"column":17},"end":{"line":18,"column":38}},"2":{"start":{"line":21,"column":2},"end":{"line":26,"column":4}},"3":{"start":{"line":30,"column":2},"end":{"line":33,"column":4}},"4":{"start":{"line":37,"column":2},"end":{"line":40,"column":4}},"5":{"start":{"line":44,"column":2},"end":{"line":49,"column":4}},"6":{"start":{"line":53,"column":2},"end":{"line":64,"column":4}},"7":{"start":{"line":54,"column":4},"end":{"line":54,"column":34}},"8":{"start":{"line":55,"column":4},"end":{"line":63,"column":10}},"9":{"start":{"line":57,"column":8},"end":{"line":57,"column":44}},"10":{"start":{"line":58,"column":8},"end":{"line":58,"column":43}},"11":{"start":{"line":60,"column":25},"end":{"line":63,"column":8}},"12":{"start":{"line":68,"column":2},"end":{"line":74,"column":4}},"13":{"start":{"line":69,"column":4},"end":{"line":71,"column":7}},"14":{"start":{"line":72,"column":18},"end":{"line":72,"column":28}},"15":{"start":{"line":73,"column":4},"end":{"line":73,"column":21}},"16":{"start":{"line":78,"column":2},"end":{"line":83,"column":4}},"17":{"start":{"line":79,"column":4},"end":{"line":81,"column":7}},"18":{"start":{"line":82,"column":4},"end":{"line":82,"column":17}},"19":{"start":{"line":87,"column":2},"end":{"line":89,"column":4}},"20":{"start":{"line":93,"column":2},"end":{"line":95,"column":4}},"21":{"start":{"line":99,"column":2},"end":{"line":101,"column":4}},"22":{"start":{"line":106,"column":19},"end":{"line":106,"column":24}},"23":{"start":{"line":107,"column":25},"end":{"line":107,"column":59}},"24":{"start":{"line":108,"column":23},"end":{"line":108,"column":109}},"25":{"start":{"line":108,"column":80},"end":{"line":108,"column":107}},"26":{"start":{"line":109,"column":24},"end":{"line":109,"column":113}},"27":{"start":{"line":109,"column":84},"end":{"line":109,"column":111}},"28":{"start":{"line":110,"column":2},"end":{"line":113,"column":3}},"29":{"start":{"line":111,"column":4},"end":{"line":111,"column":46}},"30":{"start":{"line":112,"column":4},"end":{"line":112,"column":22}},"31":{"start":{"line":114,"column":2},"end":{"line":117,"column":3}},"32":{"start":{"line":115,"column":4},"end":{"line":115,"column":52}},"33":{"start":{"line":116,"column":4},"end":{"line":116,"column":22}},"34":{"start":{"line":118,"column":2},"end":{"line":121,"column":4}},"35":{"start":{"line":125,"column":2},"end":{"line":211,"column":4}},"36":{"start":{"line":126,"column":18},"end":{"line":126,"column":28}},"37":{"start":{"line":127,"column":4},"end":{"line":129,"column":5}},"38":{"start":{"line":128,"column":6},"end":{"line":128,"column":31}},"39":{"start":{"line":130,"column":4},"end":{"line":130,"column":35}},"40":{"start":{"line":131,"column":4},"end":{"line":133,"column":5}},"41":{"start":{"line":132,"column":6},"end":{"line":132,"column":30}},"42":{"start":{"line":134,"column":23},"end":{"line":134,"column":55}},"43":{"start":{"line":135,"column":4},"end":{"line":135,"column":40}},"44":{"start":{"line":137,"column":4},"end":{"line":140,"column":5}},"45":{"start":{"line":138,"column":27},"end":{"line":138,"column":85}},"46":{"start":{"line":138,"column":57},"end":{"line":138,"column":84}},"47":{"start":{"line":139,"column":6},"end":{"line":139,"column":50}},"48":{"start":{"line":141,"column":4},"end":{"line":174,"column":5}},"49":{"start":{"line":142,"column":6},"end":{"line":173,"column":11}},"50":{"start":{"line":144,"column":10},"end":{"line":144,"column":39}},"51":{"start":{"line":145,"column":10},"end":{"line":145,"column":45}},"52":{"start":{"line":146,"column":49},"end":{"line":146,"column":93}},"53":{"start":{"line":147,"column":10},"end":{"line":149,"column":11}},"54":{"start":{"line":148,"column":12},"end":{"line":148,"column":46}},"55":{"start":{"line":150,"column":10},"end":{"line":150,"column":47}},"56":{"start":{"line":151,"column":10},"end":{"line":151,"column":41}},"57":{"start":{"line":152,"column":10},"end":{"line":162,"column":11}},"58":{"start":{"line":153,"column":12},"end":{"line":161,"column":13}},"59":{"start":{"line":154,"column":14},"end":{"line":154,"column":40}},"60":{"start":{"line":155,"column":14},"end":{"line":155,"column":55}},"61":{"start":{"line":156,"column":14},"end":{"line":156,"column":82}},"62":{"start":{"line":156,"column":31},"end":{"line":156,"column":74}},"63":{"start":{"line":157,"column":14},"end":{"line":157,"column":49}},"64":{"start":{"line":159,"column":14},"end":{"line":159,"column":40}},"65":{"start":{"line":160,"column":14},"end":{"line":160,"column":55}},"66":{"start":{"line":165,"column":10},"end":{"line":165,"column":39}},"67":{"start":{"line":166,"column":10},"end":{"line":172,"column":11}},"68":{"start":{"line":167,"column":12},"end":{"line":167,"column":53}},"69":{"start":{"line":168,"column":17},"end":{"line":172,"column":11}},"70":{"start":{"line":169,"column":12},"end":{"line":169,"column":53}},"71":{"start":{"line":171,"column":12},"end":{"line":171,"column":53}},"72":{"start":{"line":176,"column":4},"end":{"line":210,"column":9}},"73":{"start":{"line":178,"column":8},"end":{"line":178,"column":37}},"74":{"start":{"line":179,"column":47},"end":{"line":179,"column":91}},"75":{"start":{"line":180,"column":8},"end":{"line":189,"column":9}},"76":{"start":{"line":181,"column":10},"end":{"line":181,"column":50}},"77":{"start":{"line":182,"column":10},"end":{"line":182,"column":45}},"78":{"start":{"line":183,"column":10},"end":{"line":183,"column":94}},"79":{"start":{"line":184,"column":10},"end":{"line":184,"column":44}},"80":{"start":{"line":186,"column":10},"end":{"line":186,"column":50}},"81":{"start":{"line":187,"column":10},"end":{"line":187,"column":45}},"82":{"start":{"line":188,"column":10},"end":{"line":188,"column":94}},"83":{"start":{"line":190,"column":8},"end":{"line":190,"column":39}},"84":{"start":{"line":191,"column":8},"end":{"line":201,"column":9}},"85":{"start":{"line":192,"column":10},"end":{"line":200,"column":11}},"86":{"start":{"line":193,"column":12},"end":{"line":193,"column":38}},"87":{"start":{"line":194,"column":12},"end":{"line":194,"column":53}},"88":{"start":{"line":195,"column":12},"end":{"line":195,"column":80}},"89":{"start":{"line":195,"column":29},"end":{"line":195,"column":72}},"90":{"start":{"line":196,"column":12},"end":{"line":196,"column":47}},"91":{"start":{"line":198,"column":12},"end":{"line":198,"column":38}},"92":{"start":{"line":199,"column":12},"end":{"line":199,"column":53}},"93":{"start":{"line":204,"column":8},"end":{"line":204,"column":37}},"94":{"start":{"line":205,"column":8},"end":{"line":209,"column":9}},"95":{"start":{"line":206,"column":10},"end":{"line":206,"column":51}},"96":{"start":{"line":208,"column":10},"end":{"line":208,"column":51}},"97":{"start":{"line":215,"column":2},"end":{"line":217,"column":4}},"98":{"start":{"line":216,"column":4},"end":{"line":216,"column":48}},"99":{"start":{"line":221,"column":14},"end":{"line":221,"column":76}},"100":{"start":{"line":222,"column":2},"end":{"line":222,"column":14}},"101":{"start":{"line":226,"column":2},"end":{"line":228,"column":4}},"102":{"start":{"line":232,"column":2},"end":{"line":234,"column":8}},"103":{"start":{"line":233,"column":4},"end":{"line":233,"column":29}},"104":{"start":{"line":235,"column":2},"end":{"line":235,"column":24}},"105":{"start":{"line":239,"column":22},"end":{"line":239,"column":24}},"106":{"start":{"line":240,"column":2},"end":{"line":247,"column":5}},"107":{"start":{"line":241,"column":18},"end":{"line":241,"column":67}},"108":{"start":{"line":241,"column":42},"end":{"line":241,"column":66}},"109":{"start":{"line":242,"column":18},"end":{"line":242,"column":42}},"110":{"start":{"line":243,"column":4},"end":{"line":243,"column":21}},"111":{"start":{"line":244,"column":4},"end":{"line":244,"column":22}},"112":{"start":{"line":245,"column":4},"end":{"line":245,"column":28}},"113":{"start":{"line":246,"column":4},"end":{"line":246,"column":44}},"114":{"start":{"line":248,"column":2},"end":{"line":248,"column":30}},"115":{"start":{"line":252,"column":2},"end":{"line":307,"column":4}},"116":{"start":{"line":253,"column":4},"end":{"line":253,"column":39}},"117":{"start":{"line":254,"column":4},"end":{"line":306,"column":7}},"118":{"start":{"line":255,"column":6},"end":{"line":266,"column":7}},"119":{"start":{"line":256,"column":8},"end":{"line":256,"column":28}},"120":{"start":{"line":258,"column":8},"end":{"line":265,"column":14}},"121":{"start":{"line":259,"column":23},"end":{"line":259,"column":33}},"122":{"start":{"line":260,"column":24},"end":{"line":265,"column":12}},"123":{"start":{"line":268,"column":23},"end":{"line":270,"column":8}},"124":{"start":{"line":269,"column":8},"end":{"line":269,"column":27}},"125":{"start":{"line":273,"column":23},"end":{"line":273,"column":66}},"126":{"start":{"line":273,"column":45},"end":{"line":273,"column":65}},"127":{"start":{"line":274,"column":28},"end":{"line":274,"column":52}},"128":{"start":{"line":275,"column":6},"end":{"line":275,"column":34}},"129":{"start":{"line":276,"column":6},"end":{"line":276,"column":35}},"130":{"start":{"line":277,"column":6},"end":{"line":277,"column":52}},"131":{"start":{"line":280,"column":6},"end":{"line":305,"column":9}},"132":{"start":{"line":281,"column":8},"end":{"line":292,"column":9}},"133":{"start":{"line":282,"column":29},"end":{"line":284,"column":11}},"134":{"start":{"line":285,"column":10},"end":{"line":289,"column":15}},"135":{"start":{"line":287,"column":14},"end":{"line":287,"column":43}},"136":{"start":{"line":288,"column":14},"end":{"line":288,"column":29}},"137":{"start":{"line":291,"column":10},"end":{"line":291,"column":25}},"138":{"start":{"line":295,"column":27},"end":{"line":295,"column":105}},"139":{"start":{"line":296,"column":8},"end":{"line":304,"column":14}},"140":{"start":{"line":298,"column":12},"end":{"line":298,"column":96}},"141":{"start":{"line":299,"column":12},"end":{"line":299,"column":51}},"142":{"start":{"line":301,"column":29},"end":{"line":304,"column":12}},"143":{"start":{"line":311,"column":2},"end":{"line":313,"column":4}},"144":{"start":{"line":317,"column":2},"end":{"line":319,"column":4}},"145":{"start":{"line":323,"column":2},"end":{"line":326,"column":4}},"146":{"start":{"line":330,"column":2},"end":{"line":354,"column":4}},"147":{"start":{"line":331,"column":18},"end":{"line":331,"column":28}},"148":{"start":{"line":332,"column":4},"end":{"line":353,"column":9}},"149":{"start":{"line":334,"column":8},"end":{"line":345,"column":9}},"150":{"start":{"line":335,"column":10},"end":{"line":338,"column":13}},"151":{"start":{"line":339,"column":10},"end":{"line":344,"column":11}},"152":{"start":{"line":340,"column":12},"end":{"line":343,"column":15}},"153":{"start":{"line":348,"column":8},"end":{"line":348,"column":30}},"154":{"start":{"line":349,"column":8},"end":{"line":352,"column":11}},"155":{"start":{"line":358,"column":2},"end":{"line":381,"column":4}},"156":{"start":{"line":359,"column":4},"end":{"line":380,"column":9}},"157":{"start":{"line":361,"column":22},"end":{"line":361,"column":32}},"158":{"start":{"line":362,"column":8},"end":{"line":365,"column":9}},"159":{"start":{"line":363,"column":10},"end":{"line":363,"column":35}},"160":{"start":{"line":364,"column":10},"end":{"line":364,"column":41}},"161":{"start":{"line":366,"column":8},"end":{"line":369,"column":11}},"162":{"start":{"line":372,"column":8},"end":{"line":379,"column":9}},"163":{"start":{"line":373,"column":10},"end":{"line":373,"column":51}},"164":{"start":{"line":375,"column":10},"end":{"line":378,"column":13}}},"fnMap":{"0":{"name":"setProject","decl":{"start":{"line":20,"column":16},"end":{"line":20,"column":26}},"loc":{"start":{"line":20,"column":36},"end":{"line":27,"column":1}},"line":20},"1":{"name":"setProjectName","decl":{"start":{"line":29,"column":16},"end":{"line":29,"column":30}},"loc":{"start":{"line":29,"column":37},"end":{"line":34,"column":1}},"line":29},"2":{"name":"projectSaveFail","decl":{"start":{"line":36,"column":16},"end":{"line":36,"column":31}},"loc":{"start":{"line":36,"column":39},"end":{"line":41,"column":1}},"line":36},"3":{"name":"setNewProject","decl":{"start":{"line":43,"column":16},"end":{"line":43,"column":29}},"loc":{"start":{"line":43,"column":39},"end":{"line":50,"column":1}},"line":43},"4":{"name":"getProject","decl":{"start":{"line":52,"column":16},"end":{"line":52,"column":26}},"loc":{"start":{"line":52,"column":31},"end":{"line":65,"column":1}},"line":52},"5":{"name":"(anonymous_5)","decl":{"start":{"line":53,"column":9},"end":{"line":53,"column":10}},"loc":{"start":{"line":53,"column":33},"end":{"line":64,"column":3}},"line":53},"6":{"name":"(anonymous_6)","decl":{"start":{"line":56,"column":12},"end":{"line":56,"column":13}},"loc":{"start":{"line":56,"column":26},"end":{"line":59,"column":7}},"line":56},"7":{"name":"(anonymous_7)","decl":{"start":{"line":60,"column":13},"end":{"line":60,"column":14}},"loc":{"start":{"line":60,"column":25},"end":{"line":63,"column":8}},"line":60},"8":{"name":"persistState","decl":{"start":{"line":67,"column":16},"end":{"line":67,"column":28}},"loc":{"start":{"line":67,"column":31},"end":{"line":75,"column":1}},"line":67},"9":{"name":"(anonymous_9)","decl":{"start":{"line":68,"column":9},"end":{"line":68,"column":10}},"loc":{"start":{"line":68,"column":33},"end":{"line":74,"column":3}},"line":68},"10":{"name":"clearPersistedState","decl":{"start":{"line":77,"column":16},"end":{"line":77,"column":35}},"loc":{"start":{"line":77,"column":38},"end":{"line":84,"column":1}},"line":77},"11":{"name":"(anonymous_11)","decl":{"start":{"line":78,"column":9},"end":{"line":78,"column":10}},"loc":{"start":{"line":78,"column":23},"end":{"line":83,"column":3}},"line":78},"12":{"name":"startSavingProject","decl":{"start":{"line":86,"column":16},"end":{"line":86,"column":34}},"loc":{"start":{"line":86,"column":37},"end":{"line":90,"column":1}},"line":86},"13":{"name":"endSavingProject","decl":{"start":{"line":92,"column":16},"end":{"line":92,"column":32}},"loc":{"start":{"line":92,"column":35},"end":{"line":96,"column":1}},"line":92},"14":{"name":"projectSaveSuccess","decl":{"start":{"line":98,"column":16},"end":{"line":98,"column":34}},"loc":{"start":{"line":98,"column":37},"end":{"line":102,"column":1}},"line":98},"15":{"name":"getSynchedProject","decl":{"start":{"line":105,"column":9},"end":{"line":105,"column":26}},"loc":{"start":{"line":105,"column":58},"end":{"line":122,"column":1}},"line":105},"16":{"name":"(anonymous_16)","decl":{"start":{"line":108,"column":46},"end":{"line":108,"column":47}},"loc":{"start":{"line":108,"column":80},"end":{"line":108,"column":107}},"line":108},"17":{"name":"(anonymous_17)","decl":{"start":{"line":109,"column":50},"end":{"line":109,"column":51}},"loc":{"start":{"line":109,"column":84},"end":{"line":109,"column":111}},"line":109},"18":{"name":"saveProject","decl":{"start":{"line":124,"column":16},"end":{"line":124,"column":27}},"loc":{"start":{"line":124,"column":67},"end":{"line":212,"column":1}},"line":124},"19":{"name":"(anonymous_19)","decl":{"start":{"line":125,"column":9},"end":{"line":125,"column":10}},"loc":{"start":{"line":125,"column":33},"end":{"line":211,"column":3}},"line":125},"20":{"name":"(anonymous_20)","decl":{"start":{"line":138,"column":49},"end":{"line":138,"column":50}},"loc":{"start":{"line":138,"column":57},"end":{"line":138,"column":84}},"line":138},"21":{"name":"(anonymous_21)","decl":{"start":{"line":143,"column":14},"end":{"line":143,"column":15}},"loc":{"start":{"line":143,"column":28},"end":{"line":163,"column":9}},"line":143},"22":{"name":"(anonymous_22)","decl":{"start":{"line":156,"column":25},"end":{"line":156,"column":26}},"loc":{"start":{"line":156,"column":31},"end":{"line":156,"column":74}},"line":156},"23":{"name":"(anonymous_23)","decl":{"start":{"line":164,"column":15},"end":{"line":164,"column":16}},"loc":{"start":{"line":164,"column":29},"end":{"line":173,"column":9}},"line":164},"24":{"name":"(anonymous_24)","decl":{"start":{"line":177,"column":12},"end":{"line":177,"column":13}},"loc":{"start":{"line":177,"column":26},"end":{"line":202,"column":7}},"line":177},"25":{"name":"(anonymous_25)","decl":{"start":{"line":195,"column":23},"end":{"line":195,"column":24}},"loc":{"start":{"line":195,"column":29},"end":{"line":195,"column":72}},"line":195},"26":{"name":"(anonymous_26)","decl":{"start":{"line":203,"column":13},"end":{"line":203,"column":14}},"loc":{"start":{"line":203,"column":27},"end":{"line":210,"column":7}},"line":203},"27":{"name":"autosaveProject","decl":{"start":{"line":214,"column":16},"end":{"line":214,"column":31}},"loc":{"start":{"line":214,"column":34},"end":{"line":218,"column":1}},"line":214},"28":{"name":"(anonymous_28)","decl":{"start":{"line":215,"column":9},"end":{"line":215,"column":10}},"loc":{"start":{"line":215,"column":33},"end":{"line":217,"column":3}},"line":215},"29":{"name":"exportProjectAsZip","decl":{"start":{"line":220,"column":16},"end":{"line":220,"column":34}},"loc":{"start":{"line":220,"column":46},"end":{"line":223,"column":1}},"line":220},"30":{"name":"resetProject","decl":{"start":{"line":225,"column":16},"end":{"line":225,"column":28}},"loc":{"start":{"line":225,"column":31},"end":{"line":229,"column":1}},"line":225},"31":{"name":"newProject","decl":{"start":{"line":231,"column":16},"end":{"line":231,"column":26}},"loc":{"start":{"line":231,"column":29},"end":{"line":236,"column":1}},"line":231},"32":{"name":"(anonymous_32)","decl":{"start":{"line":232,"column":13},"end":{"line":232,"column":14}},"loc":{"start":{"line":232,"column":19},"end":{"line":234,"column":3}},"line":232},"33":{"name":"generateNewIdsForChildren","decl":{"start":{"line":238,"column":9},"end":{"line":238,"column":34}},"loc":{"start":{"line":238,"column":48},"end":{"line":249,"column":1}},"line":238},"34":{"name":"(anonymous_34)","decl":{"start":{"line":240,"column":24},"end":{"line":240,"column":25}},"loc":{"start":{"line":240,"column":37},"end":{"line":247,"column":3}},"line":240},"35":{"name":"(anonymous_35)","decl":{"start":{"line":241,"column":29},"end":{"line":241,"column":30}},"loc":{"start":{"line":241,"column":42},"end":{"line":241,"column":66}},"line":241},"36":{"name":"cloneProject","decl":{"start":{"line":251,"column":16},"end":{"line":251,"column":28}},"loc":{"start":{"line":251,"column":33},"end":{"line":308,"column":1}},"line":251},"37":{"name":"(anonymous_37)","decl":{"start":{"line":252,"column":9},"end":{"line":252,"column":10}},"loc":{"start":{"line":252,"column":33},"end":{"line":307,"column":3}},"line":252},"38":{"name":"(anonymous_38)","decl":{"start":{"line":254,"column":16},"end":{"line":254,"column":17}},"loc":{"start":{"line":254,"column":37},"end":{"line":267,"column":5}},"line":254},"39":{"name":"(anonymous_39)","decl":{"start":{"line":259,"column":16},"end":{"line":259,"column":17}},"loc":{"start":{"line":259,"column":23},"end":{"line":259,"column":33}},"line":259},"40":{"name":"(anonymous_40)","decl":{"start":{"line":260,"column":16},"end":{"line":260,"column":17}},"loc":{"start":{"line":260,"column":24},"end":{"line":265,"column":12}},"line":260},"41":{"name":"(anonymous_41)","decl":{"start":{"line":267,"column":12},"end":{"line":267,"column":13}},"loc":{"start":{"line":267,"column":23},"end":{"line":306,"column":5}},"line":267},"42":{"name":"(anonymous_42)","decl":{"start":{"line":268,"column":39},"end":{"line":268,"column":40}},"loc":{"start":{"line":268,"column":49},"end":{"line":270,"column":7}},"line":268},"43":{"name":"(anonymous_43)","decl":{"start":{"line":273,"column":37},"end":{"line":273,"column":38}},"loc":{"start":{"line":273,"column":45},"end":{"line":273,"column":65}},"line":273},"44":{"name":"(anonymous_44)","decl":{"start":{"line":280,"column":21},"end":{"line":280,"column":22}},"loc":{"start":{"line":280,"column":41},"end":{"line":293,"column":7}},"line":280},"45":{"name":"(anonymous_45)","decl":{"start":{"line":286,"column":18},"end":{"line":286,"column":19}},"loc":{"start":{"line":286,"column":32},"end":{"line":289,"column":13}},"line":286},"46":{"name":"(anonymous_46)","decl":{"start":{"line":293,"column":9},"end":{"line":293,"column":10}},"loc":{"start":{"line":293,"column":18},"end":{"line":305,"column":7}},"line":293},"47":{"name":"(anonymous_47)","decl":{"start":{"line":297,"column":16},"end":{"line":297,"column":17}},"loc":{"start":{"line":297,"column":30},"end":{"line":300,"column":11}},"line":297},"48":{"name":"(anonymous_48)","decl":{"start":{"line":301,"column":17},"end":{"line":301,"column":18}},"loc":{"start":{"line":301,"column":29},"end":{"line":304,"column":12}},"line":301},"49":{"name":"showEditProjectName","decl":{"start":{"line":310,"column":16},"end":{"line":310,"column":35}},"loc":{"start":{"line":310,"column":38},"end":{"line":314,"column":1}},"line":310},"50":{"name":"hideEditProjectName","decl":{"start":{"line":316,"column":16},"end":{"line":316,"column":35}},"loc":{"start":{"line":316,"column":38},"end":{"line":320,"column":1}},"line":316},"51":{"name":"setProjectSavedTime","decl":{"start":{"line":322,"column":16},"end":{"line":322,"column":35}},"loc":{"start":{"line":322,"column":47},"end":{"line":327,"column":1}},"line":322},"52":{"name":"changeProjectName","decl":{"start":{"line":329,"column":16},"end":{"line":329,"column":33}},"loc":{"start":{"line":329,"column":47},"end":{"line":355,"column":1}},"line":329},"53":{"name":"(anonymous_53)","decl":{"start":{"line":330,"column":9},"end":{"line":330,"column":10}},"loc":{"start":{"line":330,"column":33},"end":{"line":354,"column":3}},"line":330},"54":{"name":"(anonymous_54)","decl":{"start":{"line":333,"column":12},"end":{"line":333,"column":13}},"loc":{"start":{"line":333,"column":26},"end":{"line":346,"column":7}},"line":333},"55":{"name":"(anonymous_55)","decl":{"start":{"line":347,"column":13},"end":{"line":347,"column":14}},"loc":{"start":{"line":347,"column":27},"end":{"line":353,"column":7}},"line":347},"56":{"name":"deleteProject","decl":{"start":{"line":357,"column":16},"end":{"line":357,"column":29}},"loc":{"start":{"line":357,"column":34},"end":{"line":382,"column":1}},"line":357},"57":{"name":"(anonymous_57)","decl":{"start":{"line":358,"column":9},"end":{"line":358,"column":10}},"loc":{"start":{"line":358,"column":33},"end":{"line":381,"column":3}},"line":358},"58":{"name":"(anonymous_58)","decl":{"start":{"line":360,"column":12},"end":{"line":360,"column":13}},"loc":{"start":{"line":360,"column":18},"end":{"line":370,"column":7}},"line":360},"59":{"name":"(anonymous_59)","decl":{"start":{"line":371,"column":13},"end":{"line":371,"column":14}},"loc":{"start":{"line":371,"column":27},"end":{"line":380,"column":7}},"line":371}},"branchMap":{"0":{"loc":{"start":{"line":17,"column":19},"end":{"line":17,"column":66}},"type":"cond-expr","locations":[{"start":{"line":17,"column":51},"end":{"line":17,"column":57}},{"start":{"line":17,"column":60},"end":{"line":17,"column":66}}],"line":17},"1":{"loc":{"start":{"line":110,"column":2},"end":{"line":113,"column":3}},"type":"if","locations":[{"start":{"line":110,"column":2},"end":{"line":113,"column":3}},{"start":{"line":110,"column":2},"end":{"line":113,"column":3}}],"line":110},"2":{"loc":{"start":{"line":114,"column":2},"end":{"line":117,"column":3}},"type":"if","locations":[{"start":{"line":114,"column":2},"end":{"line":117,"column":3}},{"start":{"line":114,"column":2},"end":{"line":117,"column":3}}],"line":114},"3":{"loc":{"start":{"line":124,"column":28},"end":{"line":124,"column":47}},"type":"default-arg","locations":[{"start":{"line":124,"column":43},"end":{"line":124,"column":47}}],"line":124},"4":{"loc":{"start":{"line":124,"column":49},"end":{"line":124,"column":65}},"type":"default-arg","locations":[{"start":{"line":124,"column":60},"end":{"line":124,"column":65}}],"line":124},"5":{"loc":{"start":{"line":127,"column":4},"end":{"line":129,"column":5}},"type":"if","locations":[{"start":{"line":127,"column":4},"end":{"line":129,"column":5}},{"start":{"line":127,"column":4},"end":{"line":129,"column":5}}],"line":127},"6":{"loc":{"start":{"line":131,"column":4},"end":{"line":133,"column":5}},"type":"if","locations":[{"start":{"line":131,"column":4},"end":{"line":133,"column":5}},{"start":{"line":131,"column":4},"end":{"line":133,"column":5}}],"line":131},"7":{"loc":{"start":{"line":131,"column":8},"end":{"line":131,"column":88}},"type":"binary-expr","locations":[{"start":{"line":131,"column":8},"end":{"line":131,"column":21}},{"start":{"line":131,"column":25},"end":{"line":131,"column":44}},{"start":{"line":131,"column":48},"end":{"line":131,"column":88}}],"line":131},"8":{"loc":{"start":{"line":137,"column":4},"end":{"line":140,"column":5}},"type":"if","locations":[{"start":{"line":137,"column":4},"end":{"line":140,"column":5}},{"start":{"line":137,"column":4},"end":{"line":140,"column":5}}],"line":137},"9":{"loc":{"start":{"line":141,"column":4},"end":{"line":174,"column":5}},"type":"if","locations":[{"start":{"line":141,"column":4},"end":{"line":174,"column":5}},{"start":{"line":141,"column":4},"end":{"line":174,"column":5}}],"line":141},"10":{"loc":{"start":{"line":147,"column":10},"end":{"line":149,"column":11}},"type":"if","locations":[{"start":{"line":147,"column":10},"end":{"line":149,"column":11}},{"start":{"line":147,"column":10},"end":{"line":149,"column":11}}],"line":147},"11":{"loc":{"start":{"line":152,"column":10},"end":{"line":162,"column":11}},"type":"if","locations":[{"start":{"line":152,"column":10},"end":{"line":162,"column":11}},{"start":{"line":152,"column":10},"end":{"line":162,"column":11}}],"line":152},"12":{"loc":{"start":{"line":153,"column":12},"end":{"line":161,"column":13}},"type":"if","locations":[{"start":{"line":153,"column":12},"end":{"line":161,"column":13}},{"start":{"line":153,"column":12},"end":{"line":161,"column":13}}],"line":153},"13":{"loc":{"start":{"line":153,"column":16},"end":{"line":153,"column":73}},"type":"binary-expr","locations":[{"start":{"line":153,"column":16},"end":{"line":153,"column":43}},{"start":{"line":153,"column":47},"end":{"line":153,"column":73}}],"line":153},"14":{"loc":{"start":{"line":166,"column":10},"end":{"line":172,"column":11}},"type":"if","locations":[{"start":{"line":166,"column":10},"end":{"line":172,"column":11}},{"start":{"line":166,"column":10},"end":{"line":172,"column":11}}],"line":166},"15":{"loc":{"start":{"line":168,"column":17},"end":{"line":172,"column":11}},"type":"if","locations":[{"start":{"line":168,"column":17},"end":{"line":172,"column":11}},{"start":{"line":168,"column":17},"end":{"line":172,"column":11}}],"line":168},"16":{"loc":{"start":{"line":180,"column":8},"end":{"line":189,"column":9}},"type":"if","locations":[{"start":{"line":180,"column":8},"end":{"line":189,"column":9}},{"start":{"line":180,"column":8},"end":{"line":189,"column":9}}],"line":180},"17":{"loc":{"start":{"line":191,"column":8},"end":{"line":201,"column":9}},"type":"if","locations":[{"start":{"line":191,"column":8},"end":{"line":201,"column":9}},{"start":{"line":191,"column":8},"end":{"line":201,"column":9}}],"line":191},"18":{"loc":{"start":{"line":192,"column":10},"end":{"line":200,"column":11}},"type":"if","locations":[{"start":{"line":192,"column":10},"end":{"line":200,"column":11}},{"start":{"line":192,"column":10},"end":{"line":200,"column":11}}],"line":192},"19":{"loc":{"start":{"line":205,"column":8},"end":{"line":209,"column":9}},"type":"if","locations":[{"start":{"line":205,"column":8},"end":{"line":209,"column":9}},{"start":{"line":205,"column":8},"end":{"line":209,"column":9}}],"line":205},"20":{"loc":{"start":{"line":255,"column":6},"end":{"line":266,"column":7}},"type":"if","locations":[{"start":{"line":255,"column":6},"end":{"line":266,"column":7}},{"start":{"line":255,"column":6},"end":{"line":266,"column":7}}],"line":255},"21":{"loc":{"start":{"line":281,"column":8},"end":{"line":292,"column":9}},"type":"if","locations":[{"start":{"line":281,"column":8},"end":{"line":292,"column":9}},{"start":{"line":281,"column":8},"end":{"line":292,"column":9}}],"line":281},"22":{"loc":{"start":{"line":281,"column":12},"end":{"line":281,"column":54}},"type":"binary-expr","locations":[{"start":{"line":281,"column":12},"end":{"line":281,"column":20}},{"start":{"line":281,"column":24},"end":{"line":281,"column":54}}],"line":281},"23":{"loc":{"start":{"line":334,"column":8},"end":{"line":345,"column":9}},"type":"if","locations":[{"start":{"line":334,"column":8},"end":{"line":345,"column":9}},{"start":{"line":334,"column":8},"end":{"line":345,"column":9}}],"line":334},"24":{"loc":{"start":{"line":339,"column":10},"end":{"line":344,"column":11}},"type":"if","locations":[{"start":{"line":339,"column":10},"end":{"line":344,"column":11}},{"start":{"line":339,"column":10},"end":{"line":344,"column":11}}],"line":339},"25":{"loc":{"start":{"line":362,"column":8},"end":{"line":365,"column":9}},"type":"if","locations":[{"start":{"line":362,"column":8},"end":{"line":365,"column":9}},{"start":{"line":362,"column":8},"end":{"line":365,"column":9}}],"line":362},"26":{"loc":{"start":{"line":372,"column":8},"end":{"line":379,"column":9}},"type":"if","locations":[{"start":{"line":372,"column":8},"end":{"line":379,"column":9}},{"start":{"line":372,"column":8},"end":{"line":379,"column":9}}],"line":372}},"s":{"0":2,"1":2,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0,"27":0,"28":0,"29":0,"30":0,"31":0,"32":0,"33":0,"34":0,"35":0,"36":0,"37":0,"38":0,"39":0,"40":0,"41":0,"42":0,"43":0,"44":0,"45":0,"46":0,"47":0,"48":0,"49":0,"50":0,"51":0,"52":0,"53":0,"54":0,"55":0,"56":0,"57":0,"58":0,"59":0,"60":0,"61":0,"62":0,"63":0,"64":0,"65":0,"66":0,"67":0,"68":0,"69":0,"70":0,"71":0,"72":0,"73":0,"74":0,"75":0,"76":0,"77":0,"78":0,"79":0,"80":0,"81":0,"82":0,"83":0,"84":0,"85":0,"86":0,"87":0,"88":0,"89":0,"90":0,"91":0,"92":0,"93":0,"94":0,"95":0,"96":0,"97":0,"98":0,"99":0,"100":0,"101":0,"102":0,"103":0,"104":0,"105":0,"106":0,"107":0,"108":0,"109":0,"110":0,"111":0,"112":0,"113":0,"114":0,"115":0,"116":0,"117":0,"118":0,"119":0,"120":0,"121":0,"122":0,"123":0,"124":0,"125":0,"126":0,"127":0,"128":0,"129":0,"130":0,"131":0,"132":0,"133":0,"134":0,"135":0,"136":0,"137":0,"138":0,"139":0,"140":0,"141":0,"142":0,"143":0,"144":0,"145":0,"146":0,"147":0,"148":0,"149":0,"150":0,"151":0,"152":0,"153":0,"154":0,"155":0,"156":0,"157":0,"158":0,"159":0,"160":0,"161":0,"162":0,"163":0,"164":0},"f":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0,"27":0,"28":0,"29":0,"30":0,"31":0,"32":0,"33":0,"34":0,"35":0,"36":0,"37":0,"38":0,"39":0,"40":0,"41":0,"42":0,"43":0,"44":0,"45":0,"46":0,"47":0,"48":0,"49":0,"50":0,"51":0,"52":0,"53":0,"54":0,"55":0,"56":0,"57":0,"58":0,"59":0},"b":{"0":[2,0],"1":[0,0],"2":[0,0],"3":[0],"4":[0],"5":[0,0],"6":[0,0],"7":[0,0,0],"8":[0,0],"9":[0,0],"10":[0,0],"11":[0,0],"12":[0,0],"13":[0,0],"14":[0,0],"15":[0,0],"16":[0,0],"17":[0,0],"18":[0,0],"19":[0,0],"20":[0,0],"21":[0,0],"22":[0,0],"23":[0,0],"24":[0,0],"25":[0,0],"26":[0,0]},"_coverageSchema":"43e27e138ebf9cfc5966b082cf9a028302ed4184","hash":"24eda172676f7480bdd1b0ec28bc04f1df9ca195"} +,"/home/lalis/git/p5.js-web-editor/client/modules/IDE/actions/toast.js": {"path":"/home/lalis/git/p5.js-web-editor/client/modules/IDE/actions/toast.js","statementMap":{"0":{"start":{"line":4,"column":2},"end":{"line":6,"column":4}},"1":{"start":{"line":10,"column":2},"end":{"line":15,"column":4}},"2":{"start":{"line":11,"column":4},"end":{"line":13,"column":7}},"3":{"start":{"line":14,"column":4},"end":{"line":14,"column":50}},"4":{"start":{"line":14,"column":21},"end":{"line":14,"column":42}},"5":{"start":{"line":19,"column":2},"end":{"line":22,"column":4}}},"fnMap":{"0":{"name":"hideToast","decl":{"start":{"line":3,"column":16},"end":{"line":3,"column":25}},"loc":{"start":{"line":3,"column":28},"end":{"line":7,"column":1}},"line":3},"1":{"name":"showToast","decl":{"start":{"line":9,"column":16},"end":{"line":9,"column":25}},"loc":{"start":{"line":9,"column":32},"end":{"line":16,"column":1}},"line":9},"2":{"name":"(anonymous_2)","decl":{"start":{"line":10,"column":9},"end":{"line":10,"column":10}},"loc":{"start":{"line":10,"column":23},"end":{"line":15,"column":3}},"line":10},"3":{"name":"(anonymous_3)","decl":{"start":{"line":14,"column":15},"end":{"line":14,"column":16}},"loc":{"start":{"line":14,"column":21},"end":{"line":14,"column":42}},"line":14},"4":{"name":"setToastText","decl":{"start":{"line":18,"column":16},"end":{"line":18,"column":28}},"loc":{"start":{"line":18,"column":35},"end":{"line":23,"column":1}},"line":18}},"branchMap":{},"s":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0},"f":{"0":0,"1":0,"2":0,"3":0,"4":0},"b":{},"_coverageSchema":"43e27e138ebf9cfc5966b082cf9a028302ed4184","hash":"63fb7146c3a7126b73465fbc20fcb477a5059233"} +,"/home/lalis/git/p5.js-web-editor/client/modules/IDE/components/FileNode.jsx": {"path":"/home/lalis/git/p5.js-web-editor/client/modules/IDE/components/FileNode.jsx","statementMap":{"0":{"start":{"line":10,"column":21},"end":{"line":10,"column":72}},"1":{"start":{"line":11,"column":23},"end":{"line":11,"column":74}},"2":{"start":{"line":12,"column":22},"end":{"line":12,"column":72}},"3":{"start":{"line":13,"column":16},"end":{"line":13,"column":51}},"4":{"start":{"line":17,"column":4},"end":{"line":17,"column":17}},"5":{"start":{"line":18,"column":4},"end":{"line":18,"column":51}},"6":{"start":{"line":19,"column":4},"end":{"line":19,"column":57}},"7":{"start":{"line":20,"column":4},"end":{"line":20,"column":69}},"8":{"start":{"line":21,"column":4},"end":{"line":21,"column":61}},"9":{"start":{"line":22,"column":4},"end":{"line":22,"column":59}},"10":{"start":{"line":23,"column":4},"end":{"line":23,"column":63}},"11":{"start":{"line":24,"column":4},"end":{"line":24,"column":59}},"12":{"start":{"line":25,"column":4},"end":{"line":25,"column":61}},"13":{"start":{"line":26,"column":4},"end":{"line":26,"column":61}},"14":{"start":{"line":27,"column":4},"end":{"line":27,"column":59}},"15":{"start":{"line":28,"column":4},"end":{"line":28,"column":61}},"16":{"start":{"line":30,"column":4},"end":{"line":35,"column":6}},"17":{"start":{"line":39,"column":4},"end":{"line":39,"column":39}},"18":{"start":{"line":43,"column":4},"end":{"line":43,"column":40}},"19":{"start":{"line":44,"column":4},"end":{"line":48,"column":12}},"20":{"start":{"line":45,"column":6},"end":{"line":47,"column":7}},"21":{"start":{"line":46,"column":8},"end":{"line":46,"column":31}},"22":{"start":{"line":52,"column":4},"end":{"line":52,"column":34}},"23":{"start":{"line":56,"column":28},"end":{"line":56,"column":38}},"24":{"start":{"line":57,"column":41},"end":{"line":57,"column":51}},"25":{"start":{"line":59,"column":4},"end":{"line":61,"column":5}},"26":{"start":{"line":60,"column":6},"end":{"line":60,"column":38}},"27":{"start":{"line":65,"column":4},"end":{"line":65,"column":24}},"28":{"start":{"line":66,"column":4},"end":{"line":68,"column":5}},"29":{"start":{"line":67,"column":6},"end":{"line":67,"column":48}},"30":{"start":{"line":72,"column":20},"end":{"line":72,"column":38}},"31":{"start":{"line":73,"column":4},"end":{"line":73,"column":44}},"32":{"start":{"line":77,"column":4},"end":{"line":79,"column":5}},"33":{"start":{"line":78,"column":6},"end":{"line":78,"column":30}},"34":{"start":{"line":83,"column":29},"end":{"line":83,"column":73}},"35":{"start":{"line":84,"column":29},"end":{"line":84,"column":68}},"36":{"start":{"line":85,"column":22},"end":{"line":85,"column":51}},"37":{"start":{"line":86,"column":24},"end":{"line":86,"column":40}},"38":{"start":{"line":87,"column":27},"end":{"line":87,"column":64}},"39":{"start":{"line":88,"column":33},"end":{"line":88,"column":78}},"40":{"start":{"line":89,"column":29},"end":{"line":90,"column":80}},"41":{"start":{"line":91,"column":29},"end":{"line":91,"column":47}},"42":{"start":{"line":92,"column":29},"end":{"line":92,"column":84}},"43":{"start":{"line":93,"column":4},"end":{"line":95,"column":39}},"44":{"start":{"line":94,"column":6},"end":{"line":94,"column":60}},"45":{"start":{"line":95,"column":11},"end":{"line":95,"column":39}},"46":{"start":{"line":99,"column":4},"end":{"line":99,"column":23}},"47":{"start":{"line":100,"column":4},"end":{"line":102,"column":5}},"48":{"start":{"line":101,"column":6},"end":{"line":101,"column":13}},"49":{"start":{"line":103,"column":4},"end":{"line":108,"column":5}},"50":{"start":{"line":104,"column":6},"end":{"line":104,"column":46}},"51":{"start":{"line":106,"column":6},"end":{"line":106,"column":51}},"52":{"start":{"line":107,"column":6},"end":{"line":107,"column":45}},"53":{"start":{"line":112,"column":4},"end":{"line":112,"column":44}},"54":{"start":{"line":116,"column":4},"end":{"line":116,"column":43}},"55":{"start":{"line":120,"column":4},"end":{"line":120,"column":44}},"56":{"start":{"line":124,"column":4},"end":{"line":128,"column":6}},"57":{"start":{"line":132,"column":22},"end":{"line":139,"column":6}},"58":{"start":{"line":141,"column":4},"end":{"line":287,"column":6}},"59":{"start":{"line":144,"column":10},"end":{"line":275,"column":11}},"60":{"start":{"line":145,"column":12},"end":{"line":274,"column":14}},"61":{"start":{"line":149,"column":18},"end":{"line":155,"column":19}},"62":{"start":{"line":150,"column":20},"end":{"line":154,"column":22}},"63":{"start":{"line":156,"column":18},"end":{"line":171,"column":20}},"64":{"start":{"line":160,"column":39},"end":{"line":160,"column":83}},"65":{"start":{"line":166,"column":39},"end":{"line":166,"column":83}},"66":{"start":{"line":180,"column":38},"end":{"line":180,"column":67}},"67":{"start":{"line":182,"column":20},"end":{"line":182,"column":44}},"68":{"start":{"line":183,"column":20},"end":{"line":183,"column":44}},"69":{"start":{"line":190,"column":38},"end":{"line":190,"column":85}},"70":{"start":{"line":201,"column":22},"end":{"line":218,"column":23}},"71":{"start":{"line":202,"column":24},"end":{"line":217,"column":26}},"72":{"start":{"line":207,"column":32},"end":{"line":207,"column":66}},"73":{"start":{"line":208,"column":32},"end":{"line":208,"column":76}},"74":{"start":{"line":208,"column":49},"end":{"line":208,"column":71}},"75":{"start":{"line":221,"column":22},"end":{"line":238,"column":23}},"76":{"start":{"line":222,"column":24},"end":{"line":237,"column":26}},"77":{"start":{"line":227,"column":32},"end":{"line":227,"column":68}},"78":{"start":{"line":228,"column":32},"end":{"line":228,"column":76}},"79":{"start":{"line":228,"column":49},"end":{"line":228,"column":71}},"80":{"start":{"line":243,"column":26},"end":{"line":243,"column":66}},"81":{"start":{"line":244,"column":26},"end":{"line":244,"column":50}},"82":{"start":{"line":245,"column":26},"end":{"line":245,"column":74}},"83":{"start":{"line":245,"column":43},"end":{"line":245,"column":69}},"84":{"start":{"line":246,"column":26},"end":{"line":246,"column":70}},"85":{"start":{"line":246,"column":43},"end":{"line":246,"column":65}},"86":{"start":{"line":258,"column":26},"end":{"line":262,"column":27}},"87":{"start":{"line":259,"column":28},"end":{"line":259,"column":51}},"88":{"start":{"line":260,"column":28},"end":{"line":260,"column":72}},"89":{"start":{"line":261,"column":28},"end":{"line":261,"column":109}},"90":{"start":{"line":261,"column":45},"end":{"line":261,"column":102}},"91":{"start":{"line":278,"column":10},"end":{"line":284,"column":11}},"92":{"start":{"line":279,"column":12},"end":{"line":283,"column":14}},"93":{"start":{"line":291,"column":0},"end":{"line":308,"column":2}},"94":{"start":{"line":310,"column":0},"end":{"line":314,"column":2}},"95":{"start":{"line":318,"column":2},"end":{"line":318,"column":97}},"96":{"start":{"line":318,"column":34},"end":{"line":318,"column":57}},"97":{"start":{"line":322,"column":2},"end":{"line":322,"column":78}},"98":{"start":{"line":325,"column":26},"end":{"line":325,"column":80}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":16,"column":2},"end":{"line":16,"column":3}},"loc":{"start":{"line":16,"column":21},"end":{"line":36,"column":3}},"line":16},"1":{"name":"(anonymous_1)","decl":{"start":{"line":38,"column":2},"end":{"line":38,"column":3}},"loc":{"start":{"line":38,"column":21},"end":{"line":40,"column":3}},"line":38},"2":{"name":"(anonymous_2)","decl":{"start":{"line":42,"column":2},"end":{"line":42,"column":3}},"loc":{"start":{"line":42,"column":20},"end":{"line":49,"column":3}},"line":42},"3":{"name":"(anonymous_3)","decl":{"start":{"line":44,"column":15},"end":{"line":44,"column":16}},"loc":{"start":{"line":44,"column":21},"end":{"line":48,"column":5}},"line":44},"4":{"name":"(anonymous_4)","decl":{"start":{"line":51,"column":2},"end":{"line":51,"column":3}},"loc":{"start":{"line":51,"column":20},"end":{"line":53,"column":3}},"line":51},"5":{"name":"(anonymous_5)","decl":{"start":{"line":55,"column":2},"end":{"line":55,"column":3}},"loc":{"start":{"line":55,"column":25},"end":{"line":62,"column":3}},"line":55},"6":{"name":"(anonymous_6)","decl":{"start":{"line":64,"column":2},"end":{"line":64,"column":3}},"loc":{"start":{"line":64,"column":21},"end":{"line":69,"column":3}},"line":64},"7":{"name":"(anonymous_7)","decl":{"start":{"line":71,"column":2},"end":{"line":71,"column":3}},"loc":{"start":{"line":71,"column":30},"end":{"line":74,"column":3}},"line":71},"8":{"name":"(anonymous_8)","decl":{"start":{"line":76,"column":2},"end":{"line":76,"column":3}},"loc":{"start":{"line":76,"column":24},"end":{"line":80,"column":3}},"line":76},"9":{"name":"(anonymous_9)","decl":{"start":{"line":82,"column":2},"end":{"line":82,"column":3}},"loc":{"start":{"line":82,"column":21},"end":{"line":96,"column":3}},"line":82},"10":{"name":"(anonymous_10)","decl":{"start":{"line":98,"column":2},"end":{"line":98,"column":3}},"loc":{"start":{"line":98,"column":23},"end":{"line":109,"column":3}},"line":98},"11":{"name":"(anonymous_11)","decl":{"start":{"line":111,"column":2},"end":{"line":111,"column":3}},"loc":{"start":{"line":111,"column":20},"end":{"line":113,"column":3}},"line":111},"12":{"name":"(anonymous_12)","decl":{"start":{"line":115,"column":2},"end":{"line":115,"column":3}},"loc":{"start":{"line":115,"column":21},"end":{"line":117,"column":3}},"line":115},"13":{"name":"(anonymous_13)","decl":{"start":{"line":119,"column":2},"end":{"line":119,"column":3}},"loc":{"start":{"line":119,"column":21},"end":{"line":121,"column":3}},"line":119},"14":{"name":"(anonymous_14)","decl":{"start":{"line":123,"column":2},"end":{"line":123,"column":3}},"loc":{"start":{"line":123,"column":23},"end":{"line":129,"column":3}},"line":123},"15":{"name":"(anonymous_15)","decl":{"start":{"line":131,"column":2},"end":{"line":131,"column":3}},"loc":{"start":{"line":131,"column":11},"end":{"line":288,"column":3}},"line":131},"16":{"name":"(anonymous_16)","decl":{"start":{"line":143,"column":10},"end":{"line":143,"column":11}},"loc":{"start":{"line":143,"column":16},"end":{"line":276,"column":9}},"line":143},"17":{"name":"(anonymous_17)","decl":{"start":{"line":148,"column":18},"end":{"line":148,"column":19}},"loc":{"start":{"line":148,"column":24},"end":{"line":172,"column":17}},"line":148},"18":{"name":"(anonymous_18)","decl":{"start":{"line":160,"column":33},"end":{"line":160,"column":34}},"loc":{"start":{"line":160,"column":39},"end":{"line":160,"column":83}},"line":160},"19":{"name":"(anonymous_19)","decl":{"start":{"line":166,"column":33},"end":{"line":166,"column":34}},"loc":{"start":{"line":166,"column":39},"end":{"line":166,"column":83}},"line":166},"20":{"name":"(anonymous_20)","decl":{"start":{"line":180,"column":23},"end":{"line":180,"column":24}},"loc":{"start":{"line":180,"column":36},"end":{"line":180,"column":69}},"line":180},"21":{"name":"(anonymous_21)","decl":{"start":{"line":181,"column":26},"end":{"line":181,"column":27}},"loc":{"start":{"line":181,"column":32},"end":{"line":184,"column":19}},"line":181},"22":{"name":"(anonymous_22)","decl":{"start":{"line":190,"column":23},"end":{"line":190,"column":24}},"loc":{"start":{"line":190,"column":36},"end":{"line":190,"column":87}},"line":190},"23":{"name":"(anonymous_23)","decl":{"start":{"line":200,"column":22},"end":{"line":200,"column":23}},"loc":{"start":{"line":200,"column":28},"end":{"line":219,"column":21}},"line":200},"24":{"name":"(anonymous_24)","decl":{"start":{"line":206,"column":39},"end":{"line":206,"column":40}},"loc":{"start":{"line":206,"column":45},"end":{"line":209,"column":31}},"line":206},"25":{"name":"(anonymous_25)","decl":{"start":{"line":208,"column":43},"end":{"line":208,"column":44}},"loc":{"start":{"line":208,"column":49},"end":{"line":208,"column":71}},"line":208},"26":{"name":"(anonymous_26)","decl":{"start":{"line":220,"column":22},"end":{"line":220,"column":23}},"loc":{"start":{"line":220,"column":28},"end":{"line":239,"column":21}},"line":220},"27":{"name":"(anonymous_27)","decl":{"start":{"line":226,"column":39},"end":{"line":226,"column":40}},"loc":{"start":{"line":226,"column":45},"end":{"line":229,"column":31}},"line":226},"28":{"name":"(anonymous_28)","decl":{"start":{"line":228,"column":43},"end":{"line":228,"column":44}},"loc":{"start":{"line":228,"column":49},"end":{"line":228,"column":71}},"line":228},"29":{"name":"(anonymous_29)","decl":{"start":{"line":242,"column":33},"end":{"line":242,"column":34}},"loc":{"start":{"line":242,"column":39},"end":{"line":247,"column":25}},"line":242},"30":{"name":"(anonymous_30)","decl":{"start":{"line":245,"column":37},"end":{"line":245,"column":38}},"loc":{"start":{"line":245,"column":43},"end":{"line":245,"column":69}},"line":245},"31":{"name":"(anonymous_31)","decl":{"start":{"line":246,"column":37},"end":{"line":246,"column":38}},"loc":{"start":{"line":246,"column":43},"end":{"line":246,"column":65}},"line":246},"32":{"name":"(anonymous_32)","decl":{"start":{"line":257,"column":33},"end":{"line":257,"column":34}},"loc":{"start":{"line":257,"column":39},"end":{"line":263,"column":25}},"line":257},"33":{"name":"(anonymous_33)","decl":{"start":{"line":261,"column":39},"end":{"line":261,"column":40}},"loc":{"start":{"line":261,"column":45},"end":{"line":261,"column":102}},"line":261},"34":{"name":"(anonymous_34)","decl":{"start":{"line":277,"column":10},"end":{"line":277,"column":11}},"loc":{"start":{"line":277,"column":16},"end":{"line":285,"column":9}},"line":277},"35":{"name":"mapStateToProps","decl":{"start":{"line":316,"column":9},"end":{"line":316,"column":24}},"loc":{"start":{"line":316,"column":42},"end":{"line":319,"column":1}},"line":316},"36":{"name":"(anonymous_36)","decl":{"start":{"line":318,"column":26},"end":{"line":318,"column":27}},"loc":{"start":{"line":318,"column":34},"end":{"line":318,"column":57}},"line":318},"37":{"name":"mapDispatchToProps","decl":{"start":{"line":321,"column":9},"end":{"line":321,"column":27}},"loc":{"start":{"line":321,"column":38},"end":{"line":323,"column":1}},"line":321}},"branchMap":{"0":{"loc":{"start":{"line":45,"column":6},"end":{"line":47,"column":7}},"type":"if","locations":[{"start":{"line":45,"column":6},"end":{"line":47,"column":7}},{"start":{"line":45,"column":6},"end":{"line":47,"column":7}}],"line":45},"1":{"loc":{"start":{"line":59,"column":4},"end":{"line":61,"column":5}},"type":"if","locations":[{"start":{"line":59,"column":4},"end":{"line":61,"column":5}},{"start":{"line":59,"column":4},"end":{"line":61,"column":5}}],"line":59},"2":{"loc":{"start":{"line":66,"column":4},"end":{"line":68,"column":5}},"type":"if","locations":[{"start":{"line":66,"column":4},"end":{"line":68,"column":5}},{"start":{"line":66,"column":4},"end":{"line":68,"column":5}}],"line":66},"3":{"loc":{"start":{"line":66,"column":8},"end":{"line":66,"column":55}},"type":"binary-expr","locations":[{"start":{"line":66,"column":8},"end":{"line":66,"column":35}},{"start":{"line":66,"column":39},"end":{"line":66,"column":55}}],"line":66},"4":{"loc":{"start":{"line":77,"column":4},"end":{"line":79,"column":5}},"type":"if","locations":[{"start":{"line":77,"column":4},"end":{"line":79,"column":5}},{"start":{"line":77,"column":4},"end":{"line":79,"column":5}}],"line":77},"5":{"loc":{"start":{"line":87,"column":27},"end":{"line":87,"column":64}},"type":"binary-expr","locations":[{"start":{"line":87,"column":27},"end":{"line":87,"column":43}},{"start":{"line":87,"column":47},"end":{"line":87,"column":64}}],"line":87},"6":{"loc":{"start":{"line":88,"column":33},"end":{"line":88,"column":78}},"type":"binary-expr","locations":[{"start":{"line":88,"column":33},"end":{"line":88,"column":65}},{"start":{"line":88,"column":69},"end":{"line":88,"column":78}}],"line":88},"7":{"loc":{"start":{"line":89,"column":29},"end":{"line":90,"column":80}},"type":"binary-expr","locations":[{"start":{"line":89,"column":29},"end":{"line":89,"column":45}},{"start":{"line":89,"column":49},"end":{"line":89,"column":65}},{"start":{"line":90,"column":9},"end":{"line":90,"column":80}}],"line":89},"8":{"loc":{"start":{"line":92,"column":29},"end":{"line":92,"column":84}},"type":"binary-expr","locations":[{"start":{"line":92,"column":29},"end":{"line":92,"column":45}},{"start":{"line":92,"column":49},"end":{"line":92,"column":84}}],"line":92},"9":{"loc":{"start":{"line":93,"column":4},"end":{"line":95,"column":39}},"type":"if","locations":[{"start":{"line":93,"column":4},"end":{"line":95,"column":39}},{"start":{"line":93,"column":4},"end":{"line":95,"column":39}}],"line":93},"10":{"loc":{"start":{"line":93,"column":8},"end":{"line":93,"column":106}},"type":"binary-expr","locations":[{"start":{"line":93,"column":8},"end":{"line":93,"column":24}},{"start":{"line":93,"column":28},"end":{"line":93,"column":42}},{"start":{"line":93,"column":46},"end":{"line":93,"column":62}},{"start":{"line":93,"column":66},"end":{"line":93,"column":82}},{"start":{"line":93,"column":86},"end":{"line":93,"column":106}}],"line":93},"11":{"loc":{"start":{"line":100,"column":4},"end":{"line":102,"column":5}},"type":"if","locations":[{"start":{"line":100,"column":4},"end":{"line":102,"column":5}},{"start":{"line":100,"column":4},"end":{"line":102,"column":5}}],"line":100},"12":{"loc":{"start":{"line":103,"column":4},"end":{"line":108,"column":5}},"type":"if","locations":[{"start":{"line":103,"column":4},"end":{"line":108,"column":5}},{"start":{"line":103,"column":4},"end":{"line":108,"column":5}}],"line":103},"13":{"loc":{"start":{"line":144,"column":10},"end":{"line":275,"column":11}},"type":"if","locations":[{"start":{"line":144,"column":10},"end":{"line":275,"column":11}},{"start":{"line":144,"column":10},"end":{"line":275,"column":11}}],"line":144},"14":{"loc":{"start":{"line":149,"column":18},"end":{"line":155,"column":19}},"type":"if","locations":[{"start":{"line":149,"column":18},"end":{"line":155,"column":19}},{"start":{"line":149,"column":18},"end":{"line":155,"column":19}}],"line":149},"15":{"loc":{"start":{"line":201,"column":22},"end":{"line":218,"column":23}},"type":"if","locations":[{"start":{"line":201,"column":22},"end":{"line":218,"column":23}},{"start":{"line":201,"column":22},"end":{"line":218,"column":23}}],"line":201},"16":{"loc":{"start":{"line":221,"column":22},"end":{"line":238,"column":23}},"type":"if","locations":[{"start":{"line":221,"column":22},"end":{"line":238,"column":23}},{"start":{"line":221,"column":22},"end":{"line":238,"column":23}}],"line":221},"17":{"loc":{"start":{"line":258,"column":26},"end":{"line":262,"column":27}},"type":"if","locations":[{"start":{"line":258,"column":26},"end":{"line":262,"column":27}},{"start":{"line":258,"column":26},"end":{"line":262,"column":27}}],"line":258},"18":{"loc":{"start":{"line":278,"column":10},"end":{"line":284,"column":11}},"type":"if","locations":[{"start":{"line":278,"column":10},"end":{"line":284,"column":11}},{"start":{"line":278,"column":10},"end":{"line":284,"column":11}}],"line":278},"19":{"loc":{"start":{"line":318,"column":9},"end":{"line":318,"column":96}},"type":"binary-expr","locations":[{"start":{"line":318,"column":9},"end":{"line":318,"column":58}},{"start":{"line":318,"column":62},"end":{"line":318,"column":96}}],"line":318}},"s":{"0":1,"1":1,"2":1,"3":1,"4":3,"5":3,"6":3,"7":3,"8":3,"9":3,"10":3,"11":3,"12":3,"13":3,"14":3,"15":3,"16":3,"17":0,"18":0,"19":0,"20":0,"21":0,"22":71,"23":1,"24":1,"25":1,"26":1,"27":0,"28":0,"29":0,"30":2,"31":2,"32":0,"33":0,"34":2,"35":2,"36":2,"37":2,"38":2,"39":2,"40":2,"41":2,"42":2,"43":2,"44":1,"45":1,"46":0,"47":0,"48":0,"49":0,"50":0,"51":0,"52":0,"53":0,"54":2,"55":2,"56":0,"57":13,"58":13,"59":13,"60":13,"61":13,"62":0,"63":13,"64":0,"65":0,"66":0,"67":2,"68":2,"69":0,"70":13,"71":0,"72":0,"73":0,"74":0,"75":13,"76":0,"77":0,"78":0,"79":0,"80":2,"81":2,"82":2,"83":0,"84":2,"85":0,"86":0,"87":0,"88":0,"89":0,"90":0,"91":13,"92":13,"93":1,"94":1,"95":0,"96":0,"97":0,"98":1},"f":{"0":3,"1":0,"2":0,"3":0,"4":71,"5":1,"6":0,"7":2,"8":0,"9":2,"10":0,"11":0,"12":2,"13":2,"14":0,"15":13,"16":13,"17":13,"18":0,"19":0,"20":0,"21":2,"22":0,"23":13,"24":0,"25":0,"26":13,"27":0,"28":0,"29":2,"30":0,"31":0,"32":0,"33":0,"34":13,"35":0,"36":0,"37":0},"b":{"0":[0,0],"1":[1,0],"2":[0,0],"3":[0,0],"4":[0,0],"5":[2,2],"6":[2,0],"7":[2,2,1],"8":[2,1],"9":[1,1],"10":[2,1,1,1,1],"11":[0,0],"12":[0,0],"13":[13,0],"14":[0,13],"15":[0,13],"16":[0,13],"17":[0,0],"18":[13,0],"19":[0,0]},"_coverageSchema":"43e27e138ebf9cfc5966b082cf9a028302ed4184","hash":"7becd2620ba46e709e63767087ce7d61c23f8f21"} +,"/home/lalis/git/p5.js-web-editor/client/modules/User/actions.js": {"path":"/home/lalis/git/p5.js-web-editor/client/modules/User/actions.js","statementMap":{"0":{"start":{"line":8,"column":18},"end":{"line":8,"column":75}},"1":{"start":{"line":9,"column":17},"end":{"line":9,"column":38}},"2":{"start":{"line":12,"column":2},"end":{"line":15,"column":4}},"3":{"start":{"line":19,"column":2},"end":{"line":30,"column":4}},"4":{"start":{"line":20,"column":4},"end":{"line":29,"column":67}},"5":{"start":{"line":22,"column":8},"end":{"line":25,"column":11}},"6":{"start":{"line":26,"column":8},"end":{"line":26,"column":38}},"7":{"start":{"line":27,"column":8},"end":{"line":27,"column":42}},"8":{"start":{"line":29,"column":25},"end":{"line":29,"column":65}},"9":{"start":{"line":34,"column":2},"end":{"line":34,"column":80}},"10":{"start":{"line":38,"column":2},"end":{"line":41,"column":4}},"11":{"start":{"line":45,"column":2},"end":{"line":48,"column":4}},"12":{"start":{"line":52,"column":2},"end":{"line":69,"column":5}},"13":{"start":{"line":53,"column":4},"end":{"line":68,"column":84}},"14":{"start":{"line":55,"column":8},"end":{"line":58,"column":11}},"15":{"start":{"line":59,"column":8},"end":{"line":62,"column":11}},"16":{"start":{"line":63,"column":8},"end":{"line":63,"column":38}},"17":{"start":{"line":64,"column":8},"end":{"line":64,"column":42}},"18":{"start":{"line":65,"column":8},"end":{"line":65,"column":18}},"19":{"start":{"line":68,"column":8},"end":{"line":68,"column":82}},"20":{"start":{"line":73,"column":2},"end":{"line":89,"column":4}},"21":{"start":{"line":74,"column":4},"end":{"line":88,"column":9}},"22":{"start":{"line":76,"column":8},"end":{"line":79,"column":11}},"23":{"start":{"line":80,"column":8},"end":{"line":83,"column":11}},"24":{"start":{"line":86,"column":24},"end":{"line":86,"column":63}},"25":{"start":{"line":87,"column":8},"end":{"line":87,"column":37}},"26":{"start":{"line":93,"column":2},"end":{"line":106,"column":4}},"27":{"start":{"line":94,"column":4},"end":{"line":105,"column":9}},"28":{"start":{"line":96,"column":22},"end":{"line":96,"column":32}},"29":{"start":{"line":97,"column":8},"end":{"line":99,"column":9}},"30":{"start":{"line":98,"column":10},"end":{"line":98,"column":51}},"31":{"start":{"line":102,"column":8},"end":{"line":104,"column":9}},"32":{"start":{"line":103,"column":10},"end":{"line":103,"column":51}},"33":{"start":{"line":110,"column":2},"end":{"line":118,"column":4}},"34":{"start":{"line":111,"column":4},"end":{"line":117,"column":67}},"35":{"start":{"line":113,"column":8},"end":{"line":115,"column":11}},"36":{"start":{"line":117,"column":25},"end":{"line":117,"column":65}},"37":{"start":{"line":122,"column":2},"end":{"line":134,"column":4}},"38":{"start":{"line":123,"column":4},"end":{"line":125,"column":7}},"39":{"start":{"line":126,"column":4},"end":{"line":133,"column":10}},"40":{"start":{"line":130,"column":25},"end":{"line":133,"column":8}},"41":{"start":{"line":138,"column":2},"end":{"line":150,"column":4}},"42":{"start":{"line":139,"column":4},"end":{"line":141,"column":7}},"43":{"start":{"line":142,"column":4},"end":{"line":149,"column":10}},"44":{"start":{"line":146,"column":25},"end":{"line":149,"column":8}},"45":{"start":{"line":154,"column":2},"end":{"line":168,"column":4}},"46":{"start":{"line":155,"column":4},"end":{"line":158,"column":7}},"47":{"start":{"line":159,"column":4},"end":{"line":167,"column":10}},"48":{"start":{"line":160,"column":24},"end":{"line":163,"column":8}},"49":{"start":{"line":164,"column":25},"end":{"line":167,"column":8}},"50":{"start":{"line":173,"column":2},"end":{"line":175,"column":4}},"51":{"start":{"line":179,"column":2},"end":{"line":187,"column":4}},"52":{"start":{"line":180,"column":4},"end":{"line":186,"column":10}},"53":{"start":{"line":184,"column":19},"end":{"line":186,"column":8}},"54":{"start":{"line":191,"column":2},"end":{"line":200,"column":4}},"55":{"start":{"line":192,"column":4},"end":{"line":199,"column":10}},"56":{"start":{"line":194,"column":8},"end":{"line":194,"column":50}},"57":{"start":{"line":195,"column":8},"end":{"line":195,"column":33}},"58":{"start":{"line":197,"column":19},"end":{"line":199,"column":8}},"59":{"start":{"line":204,"column":2},"end":{"line":207,"column":4}},"60":{"start":{"line":211,"column":2},"end":{"line":219,"column":73}},"61":{"start":{"line":212,"column":4},"end":{"line":219,"column":72}},"62":{"start":{"line":214,"column":8},"end":{"line":214,"column":55}},"63":{"start":{"line":215,"column":8},"end":{"line":215,"column":33}},"64":{"start":{"line":216,"column":8},"end":{"line":216,"column":34}},"65":{"start":{"line":217,"column":8},"end":{"line":217,"column":50}},"66":{"start":{"line":219,"column":25},"end":{"line":219,"column":71}},"67":{"start":{"line":223,"column":2},"end":{"line":226,"column":4}},"68":{"start":{"line":230,"column":2},"end":{"line":235,"column":73}},"69":{"start":{"line":231,"column":4},"end":{"line":235,"column":72}},"70":{"start":{"line":233,"column":8},"end":{"line":233,"column":53}},"71":{"start":{"line":235,"column":25},"end":{"line":235,"column":71}},"72":{"start":{"line":239,"column":2},"end":{"line":247,"column":73}},"73":{"start":{"line":240,"column":4},"end":{"line":247,"column":72}},"74":{"start":{"line":242,"column":8},"end":{"line":245,"column":11}},"75":{"start":{"line":247,"column":25},"end":{"line":247,"column":71}}},"fnMap":{"0":{"name":"authError","decl":{"start":{"line":11,"column":16},"end":{"line":11,"column":25}},"loc":{"start":{"line":11,"column":33},"end":{"line":16,"column":1}},"line":11},"1":{"name":"signUpUser","decl":{"start":{"line":18,"column":16},"end":{"line":18,"column":26}},"loc":{"start":{"line":18,"column":53},"end":{"line":31,"column":1}},"line":18},"2":{"name":"(anonymous_2)","decl":{"start":{"line":19,"column":9},"end":{"line":19,"column":10}},"loc":{"start":{"line":19,"column":23},"end":{"line":30,"column":3}},"line":19},"3":{"name":"(anonymous_3)","decl":{"start":{"line":21,"column":12},"end":{"line":21,"column":13}},"loc":{"start":{"line":21,"column":26},"end":{"line":28,"column":7}},"line":21},"4":{"name":"(anonymous_4)","decl":{"start":{"line":29,"column":13},"end":{"line":29,"column":14}},"loc":{"start":{"line":29,"column":25},"end":{"line":29,"column":65}},"line":29},"5":{"name":"loginUser","decl":{"start":{"line":33,"column":16},"end":{"line":33,"column":25}},"loc":{"start":{"line":33,"column":38},"end":{"line":35,"column":1}},"line":33},"6":{"name":"loginUserSuccess","decl":{"start":{"line":37,"column":16},"end":{"line":37,"column":32}},"loc":{"start":{"line":37,"column":39},"end":{"line":42,"column":1}},"line":37},"7":{"name":"loginUserFailure","decl":{"start":{"line":44,"column":16},"end":{"line":44,"column":32}},"loc":{"start":{"line":44,"column":40},"end":{"line":49,"column":1}},"line":44},"8":{"name":"validateAndLoginUser","decl":{"start":{"line":51,"column":16},"end":{"line":51,"column":36}},"loc":{"start":{"line":51,"column":72},"end":{"line":70,"column":1}},"line":51},"9":{"name":"(anonymous_9)","decl":{"start":{"line":52,"column":21},"end":{"line":52,"column":22}},"loc":{"start":{"line":52,"column":42},"end":{"line":69,"column":3}},"line":52},"10":{"name":"(anonymous_10)","decl":{"start":{"line":54,"column":12},"end":{"line":54,"column":13}},"loc":{"start":{"line":54,"column":26},"end":{"line":66,"column":7}},"line":54},"11":{"name":"(anonymous_11)","decl":{"start":{"line":67,"column":13},"end":{"line":67,"column":14}},"loc":{"start":{"line":68,"column":8},"end":{"line":68,"column":82}},"line":68},"12":{"name":"getUser","decl":{"start":{"line":72,"column":16},"end":{"line":72,"column":23}},"loc":{"start":{"line":72,"column":26},"end":{"line":90,"column":1}},"line":72},"13":{"name":"(anonymous_13)","decl":{"start":{"line":73,"column":9},"end":{"line":73,"column":10}},"loc":{"start":{"line":73,"column":23},"end":{"line":89,"column":3}},"line":73},"14":{"name":"(anonymous_14)","decl":{"start":{"line":75,"column":12},"end":{"line":75,"column":13}},"loc":{"start":{"line":75,"column":26},"end":{"line":84,"column":7}},"line":75},"15":{"name":"(anonymous_15)","decl":{"start":{"line":85,"column":13},"end":{"line":85,"column":14}},"loc":{"start":{"line":85,"column":27},"end":{"line":88,"column":7}},"line":85},"16":{"name":"validateSession","decl":{"start":{"line":92,"column":16},"end":{"line":92,"column":31}},"loc":{"start":{"line":92,"column":34},"end":{"line":107,"column":1}},"line":92},"17":{"name":"(anonymous_17)","decl":{"start":{"line":93,"column":9},"end":{"line":93,"column":10}},"loc":{"start":{"line":93,"column":33},"end":{"line":106,"column":3}},"line":93},"18":{"name":"(anonymous_18)","decl":{"start":{"line":95,"column":12},"end":{"line":95,"column":13}},"loc":{"start":{"line":95,"column":26},"end":{"line":100,"column":7}},"line":95},"19":{"name":"(anonymous_19)","decl":{"start":{"line":101,"column":13},"end":{"line":101,"column":14}},"loc":{"start":{"line":101,"column":27},"end":{"line":105,"column":7}},"line":101},"20":{"name":"logoutUser","decl":{"start":{"line":109,"column":16},"end":{"line":109,"column":26}},"loc":{"start":{"line":109,"column":29},"end":{"line":119,"column":1}},"line":109},"21":{"name":"(anonymous_21)","decl":{"start":{"line":110,"column":9},"end":{"line":110,"column":10}},"loc":{"start":{"line":110,"column":23},"end":{"line":118,"column":3}},"line":110},"22":{"name":"(anonymous_22)","decl":{"start":{"line":112,"column":12},"end":{"line":112,"column":13}},"loc":{"start":{"line":112,"column":18},"end":{"line":116,"column":7}},"line":112},"23":{"name":"(anonymous_23)","decl":{"start":{"line":117,"column":13},"end":{"line":117,"column":14}},"loc":{"start":{"line":117,"column":25},"end":{"line":117,"column":65}},"line":117},"24":{"name":"initiateResetPassword","decl":{"start":{"line":121,"column":16},"end":{"line":121,"column":37}},"loc":{"start":{"line":121,"column":50},"end":{"line":135,"column":1}},"line":121},"25":{"name":"(anonymous_25)","decl":{"start":{"line":122,"column":9},"end":{"line":122,"column":10}},"loc":{"start":{"line":122,"column":23},"end":{"line":134,"column":3}},"line":122},"26":{"name":"(anonymous_26)","decl":{"start":{"line":127,"column":12},"end":{"line":127,"column":13}},"loc":{"start":{"line":127,"column":18},"end":{"line":129,"column":7}},"line":127},"27":{"name":"(anonymous_27)","decl":{"start":{"line":130,"column":13},"end":{"line":130,"column":14}},"loc":{"start":{"line":130,"column":25},"end":{"line":133,"column":8}},"line":130},"28":{"name":"initiateVerification","decl":{"start":{"line":137,"column":16},"end":{"line":137,"column":36}},"loc":{"start":{"line":137,"column":39},"end":{"line":151,"column":1}},"line":137},"29":{"name":"(anonymous_29)","decl":{"start":{"line":138,"column":9},"end":{"line":138,"column":10}},"loc":{"start":{"line":138,"column":23},"end":{"line":150,"column":3}},"line":138},"30":{"name":"(anonymous_30)","decl":{"start":{"line":143,"column":12},"end":{"line":143,"column":13}},"loc":{"start":{"line":143,"column":18},"end":{"line":145,"column":7}},"line":143},"31":{"name":"(anonymous_31)","decl":{"start":{"line":146,"column":13},"end":{"line":146,"column":14}},"loc":{"start":{"line":146,"column":25},"end":{"line":149,"column":8}},"line":146},"32":{"name":"verifyEmailConfirmation","decl":{"start":{"line":153,"column":16},"end":{"line":153,"column":39}},"loc":{"start":{"line":153,"column":47},"end":{"line":169,"column":1}},"line":153},"33":{"name":"(anonymous_33)","decl":{"start":{"line":154,"column":9},"end":{"line":154,"column":10}},"loc":{"start":{"line":154,"column":23},"end":{"line":168,"column":3}},"line":154},"34":{"name":"(anonymous_34)","decl":{"start":{"line":160,"column":12},"end":{"line":160,"column":13}},"loc":{"start":{"line":160,"column":24},"end":{"line":163,"column":8}},"line":160},"35":{"name":"(anonymous_35)","decl":{"start":{"line":164,"column":13},"end":{"line":164,"column":14}},"loc":{"start":{"line":164,"column":25},"end":{"line":167,"column":8}},"line":164},"36":{"name":"resetPasswordReset","decl":{"start":{"line":172,"column":16},"end":{"line":172,"column":34}},"loc":{"start":{"line":172,"column":37},"end":{"line":176,"column":1}},"line":172},"37":{"name":"validateResetPasswordToken","decl":{"start":{"line":178,"column":16},"end":{"line":178,"column":42}},"loc":{"start":{"line":178,"column":50},"end":{"line":188,"column":1}},"line":178},"38":{"name":"(anonymous_38)","decl":{"start":{"line":179,"column":9},"end":{"line":179,"column":10}},"loc":{"start":{"line":179,"column":23},"end":{"line":187,"column":3}},"line":179},"39":{"name":"(anonymous_39)","decl":{"start":{"line":181,"column":12},"end":{"line":181,"column":13}},"loc":{"start":{"line":181,"column":18},"end":{"line":183,"column":7}},"line":181},"40":{"name":"(anonymous_40)","decl":{"start":{"line":184,"column":13},"end":{"line":184,"column":14}},"loc":{"start":{"line":184,"column":19},"end":{"line":186,"column":8}},"line":184},"41":{"name":"updatePassword","decl":{"start":{"line":190,"column":16},"end":{"line":190,"column":30}},"loc":{"start":{"line":190,"column":50},"end":{"line":201,"column":1}},"line":190},"42":{"name":"(anonymous_42)","decl":{"start":{"line":191,"column":9},"end":{"line":191,"column":10}},"loc":{"start":{"line":191,"column":23},"end":{"line":200,"column":3}},"line":191},"43":{"name":"(anonymous_43)","decl":{"start":{"line":193,"column":12},"end":{"line":193,"column":13}},"loc":{"start":{"line":193,"column":26},"end":{"line":196,"column":7}},"line":193},"44":{"name":"(anonymous_44)","decl":{"start":{"line":197,"column":13},"end":{"line":197,"column":14}},"loc":{"start":{"line":197,"column":19},"end":{"line":199,"column":8}},"line":197},"45":{"name":"updateSettingsSuccess","decl":{"start":{"line":203,"column":16},"end":{"line":203,"column":37}},"loc":{"start":{"line":203,"column":44},"end":{"line":208,"column":1}},"line":203},"46":{"name":"updateSettings","decl":{"start":{"line":210,"column":16},"end":{"line":210,"column":30}},"loc":{"start":{"line":210,"column":43},"end":{"line":220,"column":1}},"line":210},"47":{"name":"(anonymous_47)","decl":{"start":{"line":211,"column":9},"end":{"line":211,"column":10}},"loc":{"start":{"line":212,"column":4},"end":{"line":219,"column":72}},"line":212},"48":{"name":"(anonymous_48)","decl":{"start":{"line":213,"column":12},"end":{"line":213,"column":13}},"loc":{"start":{"line":213,"column":26},"end":{"line":218,"column":7}},"line":213},"49":{"name":"(anonymous_49)","decl":{"start":{"line":219,"column":13},"end":{"line":219,"column":14}},"loc":{"start":{"line":219,"column":25},"end":{"line":219,"column":71}},"line":219},"50":{"name":"createApiKeySuccess","decl":{"start":{"line":222,"column":16},"end":{"line":222,"column":35}},"loc":{"start":{"line":222,"column":42},"end":{"line":227,"column":1}},"line":222},"51":{"name":"createApiKey","decl":{"start":{"line":229,"column":16},"end":{"line":229,"column":28}},"loc":{"start":{"line":229,"column":36},"end":{"line":236,"column":1}},"line":229},"52":{"name":"(anonymous_52)","decl":{"start":{"line":230,"column":9},"end":{"line":230,"column":10}},"loc":{"start":{"line":231,"column":4},"end":{"line":235,"column":72}},"line":231},"53":{"name":"(anonymous_53)","decl":{"start":{"line":232,"column":12},"end":{"line":232,"column":13}},"loc":{"start":{"line":232,"column":26},"end":{"line":234,"column":7}},"line":232},"54":{"name":"(anonymous_54)","decl":{"start":{"line":235,"column":13},"end":{"line":235,"column":14}},"loc":{"start":{"line":235,"column":25},"end":{"line":235,"column":71}},"line":235},"55":{"name":"removeApiKey","decl":{"start":{"line":238,"column":16},"end":{"line":238,"column":28}},"loc":{"start":{"line":238,"column":36},"end":{"line":248,"column":1}},"line":238},"56":{"name":"(anonymous_56)","decl":{"start":{"line":239,"column":9},"end":{"line":239,"column":10}},"loc":{"start":{"line":240,"column":4},"end":{"line":247,"column":72}},"line":240},"57":{"name":"(anonymous_57)","decl":{"start":{"line":241,"column":12},"end":{"line":241,"column":13}},"loc":{"start":{"line":241,"column":26},"end":{"line":246,"column":7}},"line":241},"58":{"name":"(anonymous_58)","decl":{"start":{"line":247,"column":13},"end":{"line":247,"column":14}},"loc":{"start":{"line":247,"column":25},"end":{"line":247,"column":71}},"line":247}},"branchMap":{"0":{"loc":{"start":{"line":8,"column":19},"end":{"line":8,"column":66}},"type":"cond-expr","locations":[{"start":{"line":8,"column":51},"end":{"line":8,"column":57}},{"start":{"line":8,"column":60},"end":{"line":8,"column":66}}],"line":8},"1":{"loc":{"start":{"line":86,"column":24},"end":{"line":86,"column":63}},"type":"binary-expr","locations":[{"start":{"line":86,"column":24},"end":{"line":86,"column":40}},{"start":{"line":86,"column":44},"end":{"line":86,"column":63}}],"line":86},"2":{"loc":{"start":{"line":97,"column":8},"end":{"line":99,"column":9}},"type":"if","locations":[{"start":{"line":97,"column":8},"end":{"line":99,"column":9}},{"start":{"line":97,"column":8},"end":{"line":99,"column":9}}],"line":97},"3":{"loc":{"start":{"line":102,"column":8},"end":{"line":104,"column":9}},"type":"if","locations":[{"start":{"line":102,"column":8},"end":{"line":104,"column":9}},{"start":{"line":102,"column":8},"end":{"line":104,"column":9}}],"line":102}},"s":{"0":1,"1":1,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0,"27":0,"28":0,"29":0,"30":0,"31":0,"32":0,"33":0,"34":0,"35":0,"36":0,"37":0,"38":0,"39":0,"40":0,"41":0,"42":0,"43":0,"44":0,"45":0,"46":0,"47":0,"48":0,"49":0,"50":0,"51":0,"52":0,"53":0,"54":0,"55":0,"56":0,"57":0,"58":0,"59":0,"60":0,"61":0,"62":0,"63":0,"64":0,"65":0,"66":0,"67":0,"68":0,"69":0,"70":0,"71":0,"72":0,"73":0,"74":0,"75":0},"f":{"0":0,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0,"27":0,"28":0,"29":0,"30":0,"31":0,"32":0,"33":0,"34":0,"35":0,"36":0,"37":0,"38":0,"39":0,"40":0,"41":0,"42":0,"43":0,"44":0,"45":0,"46":0,"47":0,"48":0,"49":0,"50":0,"51":0,"52":0,"53":0,"54":0,"55":0,"56":0,"57":0,"58":0},"b":{"0":[1,0],"1":[0,0],"2":[0,0],"3":[0,0]},"_coverageSchema":"43e27e138ebf9cfc5966b082cf9a028302ed4184","hash":"bd3df081542c5e659eee2f4912fbb01ba95a5866"} +,"/home/lalis/git/p5.js-web-editor/client/utils/metaKey.js": {"path":"/home/lalis/git/p5.js-web-editor/client/utils/metaKey.js","statementMap":{"0":{"start":{"line":1,"column":16},"end":{"line":9,"column":4}},"1":{"start":{"line":2,"column":2},"end":{"line":6,"column":3}},"2":{"start":{"line":3,"column":4},"end":{"line":5,"column":13}},"3":{"start":{"line":8,"column":2},"end":{"line":8,"column":16}},"4":{"start":{"line":11,"column":20},"end":{"line":11,"column":57}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":1,"column":17},"end":{"line":1,"column":18}},"loc":{"start":{"line":1,"column":23},"end":{"line":9,"column":1}},"line":1}},"branchMap":{"0":{"loc":{"start":{"line":2,"column":2},"end":{"line":6,"column":3}},"type":"if","locations":[{"start":{"line":2,"column":2},"end":{"line":6,"column":3}},{"start":{"line":2,"column":2},"end":{"line":6,"column":3}}],"line":2},"1":{"loc":{"start":{"line":2,"column":6},"end":{"line":2,"column":53}},"type":"binary-expr","locations":[{"start":{"line":2,"column":6},"end":{"line":2,"column":23}},{"start":{"line":2,"column":27},"end":{"line":2,"column":53}}],"line":2},"2":{"loc":{"start":{"line":3,"column":11},"end":{"line":5,"column":12}},"type":"cond-expr","locations":[{"start":{"line":4,"column":6},"end":{"line":4,"column":11}},{"start":{"line":5,"column":6},"end":{"line":5,"column":12}}],"line":3},"3":{"loc":{"start":{"line":11,"column":20},"end":{"line":11,"column":57}},"type":"cond-expr","locations":[{"start":{"line":11,"column":40},"end":{"line":11,"column":48}},{"start":{"line":11,"column":51},"end":{"line":11,"column":57}}],"line":11}},"s":{"0":1,"1":1,"2":1,"3":0,"4":1},"f":{"0":1},"b":{"0":[1,0],"1":[1,1],"2":[0,1],"3":[0,1]},"_coverageSchema":"43e27e138ebf9cfc5966b082cf9a028302ed4184","hash":"da5b0a611e9a0c1475e13745b98beefe0cac48dc"} +,"/home/lalis/git/p5.js-web-editor/server/controllers/project.controller/createProject.js": {"path":"/home/lalis/git/p5.js-web-editor/server/controllers/project.controller/createProject.js","statementMap":{"0":{"start":{"line":5,"column":22},"end":{"line":7,"column":3}},"1":{"start":{"line":9,"column":2},"end":{"line":9,"column":57}},"2":{"start":{"line":12,"column":4},"end":{"line":12,"column":33}},"3":{"start":{"line":16,"column":4},"end":{"line":26,"column":6}},"4":{"start":{"line":20,"column":8},"end":{"line":23,"column":9}},"5":{"start":{"line":21,"column":10},"end":{"line":21,"column":24}},"6":{"start":{"line":22,"column":10},"end":{"line":22,"column":17}},"7":{"start":{"line":24,"column":8},"end":{"line":24,"column":37}},"8":{"start":{"line":30,"column":2},"end":{"line":32,"column":24}},"9":{"start":{"line":37,"column":17},"end":{"line":37,"column":64}},"10":{"start":{"line":40,"column":4},"end":{"line":44,"column":7}},"11":{"start":{"line":49,"column":4},"end":{"line":49,"column":26}},"12":{"start":{"line":53,"column":4},"end":{"line":59,"column":5}},"13":{"start":{"line":54,"column":6},"end":{"line":54,"column":50}},"14":{"start":{"line":55,"column":11},"end":{"line":59,"column":5}},"15":{"start":{"line":56,"column":6},"end":{"line":56,"column":52}},"16":{"start":{"line":58,"column":6},"end":{"line":58,"column":20}},"17":{"start":{"line":63,"column":4},"end":{"line":69,"column":5}},"18":{"start":{"line":64,"column":6},"end":{"line":64,"column":35}},"19":{"start":{"line":65,"column":20},"end":{"line":65,"column":136}},"20":{"start":{"line":66,"column":6},"end":{"line":66,"column":23}},"21":{"start":{"line":68,"column":6},"end":{"line":68,"column":18}},"22":{"start":{"line":72,"column":2},"end":{"line":96,"column":3}},"23":{"start":{"line":73,"column":4},"end":{"line":73,"column":29}},"24":{"start":{"line":75,"column":18},"end":{"line":75,"column":33}},"25":{"start":{"line":77,"column":4},"end":{"line":92,"column":27}},"26":{"start":{"line":79,"column":8},"end":{"line":84,"column":9}},"27":{"start":{"line":80,"column":10},"end":{"line":83,"column":15}},"28":{"start":{"line":82,"column":14},"end":{"line":82,"column":58}},"29":{"start":{"line":86,"column":22},"end":{"line":86,"column":122}},"30":{"start":{"line":87,"column":8},"end":{"line":87,"column":25}},"31":{"start":{"line":89,"column":8},"end":{"line":89,"column":20}},"32":{"start":{"line":94,"column":4},"end":{"line":94,"column":22}},"33":{"start":{"line":95,"column":4},"end":{"line":95,"column":31}}},"fnMap":{"0":{"name":"createProject","decl":{"start":{"line":4,"column":24},"end":{"line":4,"column":37}},"loc":{"start":{"line":4,"column":48},"end":{"line":33,"column":1}},"line":4},"1":{"name":"sendFailure","decl":{"start":{"line":11,"column":11},"end":{"line":11,"column":22}},"loc":{"start":{"line":11,"column":25},"end":{"line":13,"column":3}},"line":11},"2":{"name":"populateUserData","decl":{"start":{"line":15,"column":11},"end":{"line":15,"column":27}},"loc":{"start":{"line":15,"column":40},"end":{"line":27,"column":3}},"line":15},"3":{"name":"(anonymous_3)","decl":{"start":{"line":19,"column":6},"end":{"line":19,"column":7}},"loc":{"start":{"line":19,"column":35},"end":{"line":25,"column":7}},"line":19},"4":{"name":"apiCreateProject","decl":{"start":{"line":36,"column":16},"end":{"line":36,"column":32}},"loc":{"start":{"line":36,"column":43},"end":{"line":97,"column":1}},"line":36},"5":{"name":"sendValidationErrors","decl":{"start":{"line":39,"column":11},"end":{"line":39,"column":31}},"loc":{"start":{"line":39,"column":55},"end":{"line":45,"column":3}},"line":39},"6":{"name":"sendFailure","decl":{"start":{"line":48,"column":11},"end":{"line":48,"column":22}},"loc":{"start":{"line":48,"column":28},"end":{"line":50,"column":3}},"line":48},"7":{"name":"handleErrors","decl":{"start":{"line":52,"column":11},"end":{"line":52,"column":23}},"loc":{"start":{"line":52,"column":29},"end":{"line":60,"column":3}},"line":52},"8":{"name":"checkUserHasPermission","decl":{"start":{"line":62,"column":11},"end":{"line":62,"column":33}},"loc":{"start":{"line":62,"column":36},"end":{"line":70,"column":3}},"line":62},"9":{"name":"(anonymous_9)","decl":{"start":{"line":78,"column":12},"end":{"line":78,"column":13}},"loc":{"start":{"line":78,"column":46},"end":{"line":90,"column":7}},"line":78},"10":{"name":"(anonymous_10)","decl":{"start":{"line":81,"column":18},"end":{"line":81,"column":19}},"loc":{"start":{"line":81,"column":34},"end":{"line":83,"column":13}},"line":81}},"branchMap":{"0":{"loc":{"start":{"line":20,"column":8},"end":{"line":23,"column":9}},"type":"if","locations":[{"start":{"line":20,"column":8},"end":{"line":23,"column":9}},{"start":{"line":20,"column":8},"end":{"line":23,"column":9}}],"line":20},"1":{"loc":{"start":{"line":39,"column":43},"end":{"line":39,"column":53}},"type":"default-arg","locations":[{"start":{"line":39,"column":50},"end":{"line":39,"column":53}}],"line":39},"2":{"loc":{"start":{"line":53,"column":4},"end":{"line":59,"column":5}},"type":"if","locations":[{"start":{"line":53,"column":4},"end":{"line":59,"column":5}},{"start":{"line":53,"column":4},"end":{"line":59,"column":5}}],"line":53},"3":{"loc":{"start":{"line":55,"column":11},"end":{"line":59,"column":5}},"type":"if","locations":[{"start":{"line":55,"column":11},"end":{"line":59,"column":5}},{"start":{"line":55,"column":11},"end":{"line":59,"column":5}}],"line":55},"4":{"loc":{"start":{"line":63,"column":4},"end":{"line":69,"column":5}},"type":"if","locations":[{"start":{"line":63,"column":4},"end":{"line":69,"column":5}},{"start":{"line":63,"column":4},"end":{"line":69,"column":5}}],"line":63},"5":{"loc":{"start":{"line":79,"column":8},"end":{"line":84,"column":9}},"type":"if","locations":[{"start":{"line":79,"column":8},"end":{"line":84,"column":9}},{"start":{"line":79,"column":8},"end":{"line":84,"column":9}}],"line":79}},"s":{"0":4,"1":4,"2":2,"3":3,"4":3,"5":1,"6":1,"7":2,"8":4,"9":6,"10":5,"11":0,"12":5,"13":3,"14":2,"15":2,"16":0,"17":7,"18":1,"19":1,"20":1,"21":1,"22":6,"23":6,"24":5,"25":2,"26":2,"27":1,"28":1,"29":1,"30":1,"31":1,"32":4,"33":4},"f":{"0":4,"1":2,"2":3,"3":3,"4":6,"5":5,"6":0,"7":5,"8":7,"9":2,"10":1},"b":{"0":[1,2],"1":[3],"2":[3,2],"3":[2,0],"4":[1,6],"5":[1,1]},"_coverageSchema":"43e27e138ebf9cfc5966b082cf9a028302ed4184","hash":"fbdc0190c35b07bbc989ef7daea36279cc95e978"} +,"/home/lalis/git/p5.js-web-editor/server/controllers/project.controller/deleteProject.js": {"path":"/home/lalis/git/p5.js-web-editor/server/controllers/project.controller/deleteProject.js","statementMap":{"0":{"start":{"line":6,"column":29},"end":{"line":6,"column":80}},"1":{"start":{"line":9,"column":2},"end":{"line":19,"column":42}},"2":{"start":{"line":10,"column":4},"end":{"line":16,"column":5}},"3":{"start":{"line":11,"column":6},"end":{"line":15,"column":7}},"4":{"start":{"line":14,"column":8},"end":{"line":14,"column":20}},"5":{"start":{"line":17,"column":4},"end":{"line":17,"column":17}},"6":{"start":{"line":19,"column":17},"end":{"line":19,"column":39}},"7":{"start":{"line":24,"column":4},"end":{"line":24,"column":60}},"8":{"start":{"line":28,"column":4},"end":{"line":28,"column":96}},"9":{"start":{"line":32,"column":4},"end":{"line":35,"column":5}},"10":{"start":{"line":33,"column":6},"end":{"line":33,"column":28}},"11":{"start":{"line":34,"column":6},"end":{"line":34,"column":13}},"12":{"start":{"line":37,"column":4},"end":{"line":40,"column":5}},"13":{"start":{"line":38,"column":6},"end":{"line":38,"column":113}},"14":{"start":{"line":39,"column":6},"end":{"line":39,"column":13}},"15":{"start":{"line":42,"column":4},"end":{"line":42,"column":37}},"16":{"start":{"line":44,"column":4},"end":{"line":51,"column":7}},"17":{"start":{"line":45,"column":6},"end":{"line":48,"column":7}},"18":{"start":{"line":46,"column":8},"end":{"line":46,"column":30}},"19":{"start":{"line":47,"column":8},"end":{"line":47,"column":15}},"20":{"start":{"line":50,"column":6},"end":{"line":50,"column":28}},"21":{"start":{"line":54,"column":2},"end":{"line":56,"column":24}}},"fnMap":{"0":{"name":"deleteFilesFromS3","decl":{"start":{"line":8,"column":9},"end":{"line":8,"column":26}},"loc":{"start":{"line":8,"column":34},"end":{"line":20,"column":1}},"line":8},"1":{"name":"(anonymous_1)","decl":{"start":{"line":9,"column":35},"end":{"line":9,"column":36}},"loc":{"start":{"line":9,"column":45},"end":{"line":18,"column":3}},"line":9},"2":{"name":"(anonymous_2)","decl":{"start":{"line":19,"column":9},"end":{"line":19,"column":10}},"loc":{"start":{"line":19,"column":17},"end":{"line":19,"column":39}},"line":19},"3":{"name":"deleteProject","decl":{"start":{"line":22,"column":24},"end":{"line":22,"column":37}},"loc":{"start":{"line":22,"column":48},"end":{"line":57,"column":1}},"line":22},"4":{"name":"sendFailure","decl":{"start":{"line":23,"column":11},"end":{"line":23,"column":22}},"loc":{"start":{"line":23,"column":30},"end":{"line":25,"column":3}},"line":23},"5":{"name":"sendProjectNotFound","decl":{"start":{"line":27,"column":11},"end":{"line":27,"column":30}},"loc":{"start":{"line":27,"column":33},"end":{"line":29,"column":3}},"line":27},"6":{"name":"handleProjectDeletion","decl":{"start":{"line":31,"column":11},"end":{"line":31,"column":32}},"loc":{"start":{"line":31,"column":42},"end":{"line":52,"column":3}},"line":31},"7":{"name":"(anonymous_7)","decl":{"start":{"line":44,"column":19},"end":{"line":44,"column":20}},"loc":{"start":{"line":44,"column":43},"end":{"line":51,"column":5}},"line":44}},"branchMap":{"0":{"loc":{"start":{"line":10,"column":4},"end":{"line":16,"column":5}},"type":"if","locations":[{"start":{"line":10,"column":4},"end":{"line":16,"column":5}},{"start":{"line":10,"column":4},"end":{"line":16,"column":5}}],"line":10},"1":{"loc":{"start":{"line":11,"column":6},"end":{"line":15,"column":7}},"type":"if","locations":[{"start":{"line":11,"column":6},"end":{"line":15,"column":7}},{"start":{"line":11,"column":6},"end":{"line":15,"column":7}}],"line":11},"2":{"loc":{"start":{"line":11,"column":10},"end":{"line":13,"column":74}},"type":"binary-expr","locations":[{"start":{"line":11,"column":10},"end":{"line":11,"column":30}},{"start":{"line":12,"column":8},"end":{"line":12,"column":27}},{"start":{"line":13,"column":8},"end":{"line":13,"column":73}}],"line":11},"3":{"loc":{"start":{"line":32,"column":4},"end":{"line":35,"column":5}},"type":"if","locations":[{"start":{"line":32,"column":4},"end":{"line":35,"column":5}},{"start":{"line":32,"column":4},"end":{"line":35,"column":5}}],"line":32},"4":{"loc":{"start":{"line":37,"column":4},"end":{"line":40,"column":5}},"type":"if","locations":[{"start":{"line":37,"column":4},"end":{"line":40,"column":5}},{"start":{"line":37,"column":4},"end":{"line":40,"column":5}}],"line":37},"5":{"loc":{"start":{"line":45,"column":6},"end":{"line":48,"column":7}},"type":"if","locations":[{"start":{"line":45,"column":6},"end":{"line":48,"column":7}},{"start":{"line":45,"column":6},"end":{"line":48,"column":7}}],"line":45}},"s":{"0":1,"1":1,"2":0,"3":0,"4":0,"5":0,"6":0,"7":2,"8":1,"9":3,"10":1,"11":1,"12":2,"13":1,"14":1,"15":1,"16":1,"17":1,"18":0,"19":0,"20":1,"21":3},"f":{"0":1,"1":0,"2":0,"3":3,"4":2,"5":1,"6":3,"7":1},"b":{"0":[0,0],"1":[0,0],"2":[0,0,0],"3":[1,2],"4":[1,1],"5":[0,1]},"_coverageSchema":"43e27e138ebf9cfc5966b082cf9a028302ed4184","hash":"59629d52f4aa380c4c912ebd5f750e3ac63dab04"} +,"/home/lalis/git/p5.js-web-editor/server/controllers/project.controller/getProjectsForUser.js": {"path":"/home/lalis/git/p5.js-web-editor/server/controllers/project.controller/getProjectsForUser.js","statementMap":{"0":{"start":{"line":6,"column":26},"end":{"line":6,"column":74}},"1":{"start":{"line":9,"column":2},"end":{"line":33,"column":5}},"2":{"start":{"line":10,"column":4},"end":{"line":32,"column":7}},"3":{"start":{"line":11,"column":6},"end":{"line":14,"column":7}},"4":{"start":{"line":12,"column":8},"end":{"line":12,"column":20}},"5":{"start":{"line":13,"column":8},"end":{"line":13,"column":15}},"6":{"start":{"line":16,"column":6},"end":{"line":19,"column":7}},"7":{"start":{"line":17,"column":8},"end":{"line":17,"column":40}},"8":{"start":{"line":18,"column":8},"end":{"line":18,"column":15}},"9":{"start":{"line":21,"column":6},"end":{"line":31,"column":11}},"10":{"start":{"line":25,"column":10},"end":{"line":28,"column":11}},"11":{"start":{"line":26,"column":12},"end":{"line":26,"column":29}},"12":{"start":{"line":27,"column":12},"end":{"line":27,"column":19}},"13":{"start":{"line":30,"column":10},"end":{"line":30,"column":28}},"14":{"start":{"line":37,"column":2},"end":{"line":47,"column":3}},"15":{"start":{"line":38,"column":4},"end":{"line":46,"column":9}},"16":{"start":{"line":39,"column":24},"end":{"line":39,"column":42}},"17":{"start":{"line":41,"column":8},"end":{"line":45,"column":9}},"18":{"start":{"line":42,"column":10},"end":{"line":42,"column":87}},"19":{"start":{"line":44,"column":10},"end":{"line":44,"column":71}},"20":{"start":{"line":50,"column":2},"end":{"line":50,"column":27}},"21":{"start":{"line":51,"column":2},"end":{"line":51,"column":27}},"22":{"start":{"line":55,"column":2},"end":{"line":68,"column":3}},"23":{"start":{"line":56,"column":4},"end":{"line":67,"column":9}},"24":{"start":{"line":58,"column":29},"end":{"line":58,"column":69}},"25":{"start":{"line":58,"column":47},"end":{"line":58,"column":68}},"26":{"start":{"line":59,"column":8},"end":{"line":59,"column":45}},"27":{"start":{"line":62,"column":8},"end":{"line":66,"column":9}},"28":{"start":{"line":63,"column":10},"end":{"line":63,"column":87}},"29":{"start":{"line":65,"column":10},"end":{"line":65,"column":71}},"30":{"start":{"line":70,"column":2},"end":{"line":70,"column":61}},"31":{"start":{"line":71,"column":2},"end":{"line":71,"column":27}}},"fnMap":{"0":{"name":"getProjectsForUserName","decl":{"start":{"line":8,"column":9},"end":{"line":8,"column":31}},"loc":{"start":{"line":8,"column":42},"end":{"line":34,"column":1}},"line":8},"1":{"name":"(anonymous_1)","decl":{"start":{"line":9,"column":21},"end":{"line":9,"column":22}},"loc":{"start":{"line":9,"column":42},"end":{"line":33,"column":3}},"line":9},"2":{"name":"(anonymous_2)","decl":{"start":{"line":10,"column":31},"end":{"line":10,"column":32}},"loc":{"start":{"line":10,"column":46},"end":{"line":32,"column":5}},"line":10},"3":{"name":"(anonymous_3)","decl":{"start":{"line":24,"column":14},"end":{"line":24,"column":15}},"loc":{"start":{"line":24,"column":38},"end":{"line":31,"column":9}},"line":24},"4":{"name":"getProjectsForUser","decl":{"start":{"line":36,"column":24},"end":{"line":36,"column":42}},"loc":{"start":{"line":36,"column":53},"end":{"line":52,"column":1}},"line":36},"5":{"name":"(anonymous_5)","decl":{"start":{"line":39,"column":12},"end":{"line":39,"column":13}},"loc":{"start":{"line":39,"column":24},"end":{"line":39,"column":42}},"line":39},"6":{"name":"(anonymous_6)","decl":{"start":{"line":40,"column":13},"end":{"line":40,"column":14}},"loc":{"start":{"line":40,"column":22},"end":{"line":46,"column":7}},"line":40},"7":{"name":"apiGetProjectsForUser","decl":{"start":{"line":54,"column":16},"end":{"line":54,"column":37}},"loc":{"start":{"line":54,"column":48},"end":{"line":72,"column":1}},"line":54},"8":{"name":"(anonymous_8)","decl":{"start":{"line":57,"column":12},"end":{"line":57,"column":13}},"loc":{"start":{"line":57,"column":26},"end":{"line":60,"column":7}},"line":57},"9":{"name":"(anonymous_9)","decl":{"start":{"line":58,"column":42},"end":{"line":58,"column":43}},"loc":{"start":{"line":58,"column":47},"end":{"line":58,"column":68}},"line":58},"10":{"name":"(anonymous_10)","decl":{"start":{"line":61,"column":13},"end":{"line":61,"column":14}},"loc":{"start":{"line":61,"column":22},"end":{"line":67,"column":7}},"line":61}},"branchMap":{"0":{"loc":{"start":{"line":11,"column":6},"end":{"line":14,"column":7}},"type":"if","locations":[{"start":{"line":11,"column":6},"end":{"line":14,"column":7}},{"start":{"line":11,"column":6},"end":{"line":14,"column":7}}],"line":11},"1":{"loc":{"start":{"line":16,"column":6},"end":{"line":19,"column":7}},"type":"if","locations":[{"start":{"line":16,"column":6},"end":{"line":19,"column":7}},{"start":{"line":16,"column":6},"end":{"line":19,"column":7}}],"line":16},"2":{"loc":{"start":{"line":25,"column":10},"end":{"line":28,"column":11}},"type":"if","locations":[{"start":{"line":25,"column":10},"end":{"line":28,"column":11}},{"start":{"line":25,"column":10},"end":{"line":28,"column":11}}],"line":25},"3":{"loc":{"start":{"line":37,"column":2},"end":{"line":47,"column":3}},"type":"if","locations":[{"start":{"line":37,"column":2},"end":{"line":47,"column":3}},{"start":{"line":37,"column":2},"end":{"line":47,"column":3}}],"line":37},"4":{"loc":{"start":{"line":41,"column":8},"end":{"line":45,"column":9}},"type":"if","locations":[{"start":{"line":41,"column":8},"end":{"line":45,"column":9}},{"start":{"line":41,"column":8},"end":{"line":45,"column":9}}],"line":41},"5":{"loc":{"start":{"line":55,"column":2},"end":{"line":68,"column":3}},"type":"if","locations":[{"start":{"line":55,"column":2},"end":{"line":68,"column":3}},{"start":{"line":55,"column":2},"end":{"line":68,"column":3}}],"line":55},"6":{"loc":{"start":{"line":62,"column":8},"end":{"line":66,"column":9}},"type":"if","locations":[{"start":{"line":62,"column":8},"end":{"line":66,"column":9}},{"start":{"line":62,"column":8},"end":{"line":66,"column":9}}],"line":62}},"s":{"0":1,"1":4,"2":4,"3":4,"4":2,"5":2,"6":2,"7":2,"8":2,"9":0,"10":0,"11":0,"12":0,"13":0,"14":3,"15":2,"16":0,"17":2,"18":1,"19":1,"20":1,"21":1,"22":3,"23":2,"24":0,"25":0,"26":0,"27":2,"28":1,"29":1,"30":1,"31":1},"f":{"0":4,"1":4,"2":4,"3":0,"4":3,"5":0,"6":2,"7":3,"8":0,"9":0,"10":2},"b":{"0":[2,2],"1":[2,0],"2":[0,0],"3":[2,1],"4":[1,1],"5":[2,1],"6":[1,1]},"_coverageSchema":"43e27e138ebf9cfc5966b082cf9a028302ed4184","hash":"9b2d905c68487abab79f27ca9796867237ed0b52"} +,"/home/lalis/git/p5.js-web-editor/server/controllers/user.controller/apiKey.js": {"path":"/home/lalis/git/p5.js-web-editor/server/controllers/user.controller/apiKey.js","statementMap":{"0":{"start":{"line":10,"column":2},"end":{"line":18,"column":5}},"1":{"start":{"line":11,"column":4},"end":{"line":17,"column":7}},"2":{"start":{"line":12,"column":6},"end":{"line":14,"column":7}},"3":{"start":{"line":13,"column":8},"end":{"line":13,"column":20}},"4":{"start":{"line":15,"column":18},"end":{"line":15,"column":37}},"5":{"start":{"line":16,"column":6},"end":{"line":16,"column":51}},"6":{"start":{"line":22,"column":2},"end":{"line":63,"column":5}},"7":{"start":{"line":24,"column":6},"end":{"line":24,"column":39}},"8":{"start":{"line":25,"column":6},"end":{"line":25,"column":16}},"9":{"start":{"line":28,"column":4},"end":{"line":62,"column":7}},"10":{"start":{"line":29,"column":6},"end":{"line":32,"column":7}},"11":{"start":{"line":30,"column":8},"end":{"line":30,"column":43}},"12":{"start":{"line":31,"column":8},"end":{"line":31,"column":15}},"13":{"start":{"line":34,"column":6},"end":{"line":37,"column":7}},"14":{"start":{"line":35,"column":8},"end":{"line":35,"column":85}},"15":{"start":{"line":36,"column":8},"end":{"line":36,"column":15}},"16":{"start":{"line":39,"column":28},"end":{"line":39,"column":50}},"17":{"start":{"line":41,"column":31},"end":{"line":41,"column":101}},"18":{"start":{"line":43,"column":6},"end":{"line":61,"column":9}},"19":{"start":{"line":44,"column":8},"end":{"line":47,"column":9}},"20":{"start":{"line":45,"column":10},"end":{"line":45,"column":36}},"21":{"start":{"line":46,"column":10},"end":{"line":46,"column":17}},"22":{"start":{"line":49,"column":24},"end":{"line":57,"column":12}},"23":{"start":{"line":51,"column":27},"end":{"line":51,"column":44}},"24":{"start":{"line":52,"column":39},"end":{"line":52,"column":69}},"25":{"start":{"line":54,"column":12},"end":{"line":56,"column":21}},"26":{"start":{"line":59,"column":8},"end":{"line":59,"column":30}},"27":{"start":{"line":60,"column":8},"end":{"line":60,"column":18}},"28":{"start":{"line":67,"column":2},"end":{"line":102,"column":5}},"29":{"start":{"line":69,"column":6},"end":{"line":69,"column":39}},"30":{"start":{"line":70,"column":6},"end":{"line":70,"column":16}},"31":{"start":{"line":73,"column":4},"end":{"line":101,"column":7}},"32":{"start":{"line":74,"column":6},"end":{"line":77,"column":7}},"33":{"start":{"line":75,"column":8},"end":{"line":75,"column":30}},"34":{"start":{"line":76,"column":8},"end":{"line":76,"column":15}},"35":{"start":{"line":79,"column":6},"end":{"line":82,"column":7}},"36":{"start":{"line":80,"column":8},"end":{"line":80,"column":43}},"37":{"start":{"line":81,"column":8},"end":{"line":81,"column":15}},"38":{"start":{"line":84,"column":26},"end":{"line":84,"column":79}},"39":{"start":{"line":84,"column":51},"end":{"line":84,"column":78}},"40":{"start":{"line":85,"column":6},"end":{"line":88,"column":7}},"41":{"start":{"line":86,"column":8},"end":{"line":86,"column":56}},"42":{"start":{"line":87,"column":8},"end":{"line":87,"column":15}},"43":{"start":{"line":90,"column":6},"end":{"line":90,"column":51}},"44":{"start":{"line":92,"column":6},"end":{"line":100,"column":9}},"45":{"start":{"line":93,"column":8},"end":{"line":96,"column":9}},"46":{"start":{"line":94,"column":10},"end":{"line":94,"column":36}},"47":{"start":{"line":95,"column":10},"end":{"line":95,"column":17}},"48":{"start":{"line":98,"column":8},"end":{"line":98,"column":56}},"49":{"start":{"line":99,"column":8},"end":{"line":99,"column":18}}},"fnMap":{"0":{"name":"generateApiKey","decl":{"start":{"line":9,"column":9},"end":{"line":9,"column":23}},"loc":{"start":{"line":9,"column":26},"end":{"line":19,"column":1}},"line":9},"1":{"name":"(anonymous_1)","decl":{"start":{"line":10,"column":21},"end":{"line":10,"column":22}},"loc":{"start":{"line":10,"column":42},"end":{"line":18,"column":3}},"line":10},"2":{"name":"(anonymous_2)","decl":{"start":{"line":11,"column":27},"end":{"line":11,"column":28}},"loc":{"start":{"line":11,"column":41},"end":{"line":17,"column":5}},"line":11},"3":{"name":"createApiKey","decl":{"start":{"line":21,"column":16},"end":{"line":21,"column":28}},"loc":{"start":{"line":21,"column":39},"end":{"line":64,"column":1}},"line":21},"4":{"name":"(anonymous_4)","decl":{"start":{"line":22,"column":21},"end":{"line":22,"column":22}},"loc":{"start":{"line":22,"column":42},"end":{"line":63,"column":3}},"line":22},"5":{"name":"sendFailure","decl":{"start":{"line":23,"column":13},"end":{"line":23,"column":24}},"loc":{"start":{"line":23,"column":38},"end":{"line":26,"column":5}},"line":23},"6":{"name":"(anonymous_6)","decl":{"start":{"line":28,"column":31},"end":{"line":28,"column":32}},"loc":{"start":{"line":28,"column":52},"end":{"line":62,"column":5}},"line":28},"7":{"name":"(anonymous_7)","decl":{"start":{"line":43,"column":16},"end":{"line":43,"column":17}},"loc":{"start":{"line":43,"column":29},"end":{"line":61,"column":7}},"line":43},"8":{"name":"(anonymous_8)","decl":{"start":{"line":50,"column":15},"end":{"line":50,"column":16}},"loc":{"start":{"line":50,"column":34},"end":{"line":57,"column":11}},"line":50},"9":{"name":"removeApiKey","decl":{"start":{"line":66,"column":16},"end":{"line":66,"column":28}},"loc":{"start":{"line":66,"column":39},"end":{"line":103,"column":1}},"line":66},"10":{"name":"(anonymous_10)","decl":{"start":{"line":67,"column":21},"end":{"line":67,"column":22}},"loc":{"start":{"line":67,"column":42},"end":{"line":102,"column":3}},"line":67},"11":{"name":"sendFailure","decl":{"start":{"line":68,"column":13},"end":{"line":68,"column":24}},"loc":{"start":{"line":68,"column":38},"end":{"line":71,"column":5}},"line":68},"12":{"name":"(anonymous_12)","decl":{"start":{"line":73,"column":31},"end":{"line":73,"column":32}},"loc":{"start":{"line":73,"column":46},"end":{"line":101,"column":5}},"line":73},"13":{"name":"(anonymous_13)","decl":{"start":{"line":84,"column":44},"end":{"line":84,"column":45}},"loc":{"start":{"line":84,"column":51},"end":{"line":84,"column":78}},"line":84},"14":{"name":"(anonymous_14)","decl":{"start":{"line":92,"column":16},"end":{"line":92,"column":17}},"loc":{"start":{"line":92,"column":29},"end":{"line":100,"column":7}},"line":92}},"branchMap":{"0":{"loc":{"start":{"line":12,"column":6},"end":{"line":14,"column":7}},"type":"if","locations":[{"start":{"line":12,"column":6},"end":{"line":14,"column":7}},{"start":{"line":12,"column":6},"end":{"line":14,"column":7}}],"line":12},"1":{"loc":{"start":{"line":29,"column":6},"end":{"line":32,"column":7}},"type":"if","locations":[{"start":{"line":29,"column":6},"end":{"line":32,"column":7}},{"start":{"line":29,"column":6},"end":{"line":32,"column":7}}],"line":29},"2":{"loc":{"start":{"line":34,"column":6},"end":{"line":37,"column":7}},"type":"if","locations":[{"start":{"line":34,"column":6},"end":{"line":37,"column":7}},{"start":{"line":34,"column":6},"end":{"line":37,"column":7}}],"line":34},"3":{"loc":{"start":{"line":44,"column":8},"end":{"line":47,"column":9}},"type":"if","locations":[{"start":{"line":44,"column":8},"end":{"line":47,"column":9}},{"start":{"line":44,"column":8},"end":{"line":47,"column":9}}],"line":44},"4":{"loc":{"start":{"line":54,"column":19},"end":{"line":56,"column":20}},"type":"cond-expr","locations":[{"start":{"line":55,"column":14},"end":{"line":55,"column":49}},{"start":{"line":56,"column":14},"end":{"line":56,"column":20}}],"line":54},"5":{"loc":{"start":{"line":74,"column":6},"end":{"line":77,"column":7}},"type":"if","locations":[{"start":{"line":74,"column":6},"end":{"line":77,"column":7}},{"start":{"line":74,"column":6},"end":{"line":77,"column":7}}],"line":74},"6":{"loc":{"start":{"line":79,"column":6},"end":{"line":82,"column":7}},"type":"if","locations":[{"start":{"line":79,"column":6},"end":{"line":82,"column":7}},{"start":{"line":79,"column":6},"end":{"line":82,"column":7}}],"line":79},"7":{"loc":{"start":{"line":85,"column":6},"end":{"line":88,"column":7}},"type":"if","locations":[{"start":{"line":85,"column":6},"end":{"line":88,"column":7}},{"start":{"line":85,"column":6},"end":{"line":88,"column":7}}],"line":85},"8":{"loc":{"start":{"line":93,"column":8},"end":{"line":96,"column":9}},"type":"if","locations":[{"start":{"line":93,"column":8},"end":{"line":96,"column":9}},{"start":{"line":93,"column":8},"end":{"line":96,"column":9}}],"line":93}},"s":{"0":1,"1":1,"2":1,"3":0,"4":1,"5":1,"6":3,"7":2,"8":2,"9":3,"10":3,"11":1,"12":1,"13":2,"14":1,"15":1,"16":1,"17":1,"18":1,"19":1,"20":0,"21":0,"22":1,"23":1,"24":1,"25":1,"26":1,"27":1,"28":3,"29":2,"30":2,"31":3,"32":3,"33":0,"34":0,"35":3,"36":1,"37":1,"38":2,"39":1,"40":2,"41":1,"42":1,"43":1,"44":1,"45":1,"46":0,"47":0,"48":1,"49":1},"f":{"0":1,"1":1,"2":1,"3":3,"4":3,"5":2,"6":3,"7":1,"8":1,"9":3,"10":3,"11":2,"12":3,"13":1,"14":1},"b":{"0":[0,1],"1":[1,2],"2":[1,1],"3":[0,1],"4":[1,0],"5":[0,3],"6":[1,2],"7":[1,1],"8":[0,1]},"_coverageSchema":"43e27e138ebf9cfc5966b082cf9a028302ed4184","hash":"666f18dbc046b6ea930b757973c0ce537f10e862"} +,"/home/lalis/git/p5.js-web-editor/server/domain-objects/Project.js": {"path":"/home/lalis/git/p5.js-web-editor/server/domain-objects/Project.js","statementMap":{"0":{"start":{"line":8,"column":35},"end":{"line":8,"column":85}},"1":{"start":{"line":9,"column":38},"end":{"line":9,"column":91}},"2":{"start":{"line":17,"column":2},"end":{"line":20,"column":4}},"3":{"start":{"line":32,"column":16},"end":{"line":32,"column":18}},"4":{"start":{"line":33,"column":17},"end":{"line":33,"column":19}},"5":{"start":{"line":35,"column":2},"end":{"line":77,"column":5}},"6":{"start":{"line":36,"column":15},"end":{"line":36,"column":25}},"7":{"start":{"line":37,"column":21},"end":{"line":37,"column":41}},"8":{"start":{"line":39,"column":4},"end":{"line":70,"column":5}},"9":{"start":{"line":40,"column":21},"end":{"line":45,"column":7}},"10":{"start":{"line":47,"column":6},"end":{"line":47,"column":25}},"11":{"start":{"line":51,"column":24},"end":{"line":51,"column":65}},"12":{"start":{"line":52,"column":6},"end":{"line":52,"column":37}},"13":{"start":{"line":53,"column":6},"end":{"line":53,"column":39}},"14":{"start":{"line":55,"column":19},"end":{"line":59,"column":7}},"15":{"start":{"line":61,"column":6},"end":{"line":67,"column":7}},"16":{"start":{"line":62,"column":8},"end":{"line":62,"column":30}},"17":{"start":{"line":63,"column":13},"end":{"line":67,"column":7}},"18":{"start":{"line":64,"column":8},"end":{"line":64,"column":38}},"19":{"start":{"line":66,"column":8},"end":{"line":66,"column":73}},"20":{"start":{"line":69,"column":6},"end":{"line":69,"column":23}},"21":{"start":{"line":74,"column":4},"end":{"line":76,"column":5}},"22":{"start":{"line":75,"column":6},"end":{"line":75,"column":35}},"23":{"start":{"line":79,"column":2},"end":{"line":79,"column":27}},"24":{"start":{"line":83,"column":19},"end":{"line":87,"column":3}},"25":{"start":{"line":89,"column":28},"end":{"line":89,"column":57}},"26":{"start":{"line":91,"column":2},"end":{"line":101,"column":3}},"27":{"start":{"line":92,"column":20},"end":{"line":96,"column":1}},"28":{"start":{"line":95,"column":24},"end":{"line":95,"column":51}},"29":{"start":{"line":97,"column":18},"end":{"line":97,"column":50}},"30":{"start":{"line":98,"column":4},"end":{"line":98,"column":25}},"31":{"start":{"line":100,"column":4},"end":{"line":100,"column":16}},"32":{"start":{"line":103,"column":2},"end":{"line":103,"column":15}},"33":{"start":{"line":107,"column":2},"end":{"line":107,"column":70}},"34":{"start":{"line":107,"column":40},"end":{"line":107,"column":60}},"35":{"start":{"line":116,"column":14},"end":{"line":116,"column":16}},"36":{"start":{"line":117,"column":13},"end":{"line":117,"column":25}},"37":{"start":{"line":119,"column":2},"end":{"line":127,"column":3}},"38":{"start":{"line":120,"column":4},"end":{"line":122,"column":5}},"39":{"start":{"line":121,"column":6},"end":{"line":121,"column":55}},"40":{"start":{"line":124,"column":4},"end":{"line":124,"column":33}},"41":{"start":{"line":126,"column":4},"end":{"line":126,"column":65}},"42":{"start":{"line":129,"column":24},"end":{"line":129,"column":62}},"43":{"start":{"line":130,"column":2},"end":{"line":130,"column":30}},"44":{"start":{"line":132,"column":2},"end":{"line":132,"column":36}}},"fnMap":{"0":{"name":"toApi","decl":{"start":{"line":16,"column":16},"end":{"line":16,"column":21}},"loc":{"start":{"line":16,"column":29},"end":{"line":21,"column":1}},"line":16},"1":{"name":"transformFilesInner","decl":{"start":{"line":31,"column":9},"end":{"line":31,"column":28}},"loc":{"start":{"line":31,"column":52},"end":{"line":80,"column":1}},"line":31},"2":{"name":"(anonymous_2)","decl":{"start":{"line":35,"column":31},"end":{"line":35,"column":32}},"loc":{"start":{"line":35,"column":51},"end":{"line":77,"column":3}},"line":35},"3":{"name":"transformFiles","decl":{"start":{"line":82,"column":16},"end":{"line":82,"column":30}},"loc":{"start":{"line":82,"column":42},"end":{"line":104,"column":1}},"line":82},"4":{"name":"(anonymous_4)","decl":{"start":{"line":95,"column":19},"end":{"line":95,"column":20}},"loc":{"start":{"line":95,"column":24},"end":{"line":95,"column":51}},"line":95},"5":{"name":"containsRootHtmlFile","decl":{"start":{"line":106,"column":16},"end":{"line":106,"column":36}},"loc":{"start":{"line":106,"column":43},"end":{"line":108,"column":1}},"line":106},"6":{"name":"(anonymous_6)","decl":{"start":{"line":107,"column":32},"end":{"line":107,"column":33}},"loc":{"start":{"line":107,"column":40},"end":{"line":107,"column":60}},"line":107},"7":{"name":"toModel","decl":{"start":{"line":115,"column":16},"end":{"line":115,"column":23}},"loc":{"start":{"line":115,"column":32},"end":{"line":133,"column":1}},"line":115}},"branchMap":{"0":{"loc":{"start":{"line":31,"column":29},"end":{"line":31,"column":38}},"type":"default-arg","locations":[{"start":{"line":31,"column":36},"end":{"line":31,"column":38}}],"line":31},"1":{"loc":{"start":{"line":39,"column":4},"end":{"line":70,"column":5}},"type":"if","locations":[{"start":{"line":39,"column":4},"end":{"line":70,"column":5}},{"start":{"line":39,"column":4},"end":{"line":70,"column":5}}],"line":39},"2":{"loc":{"start":{"line":61,"column":6},"end":{"line":67,"column":7}},"type":"if","locations":[{"start":{"line":61,"column":6},"end":{"line":67,"column":7}},{"start":{"line":61,"column":6},"end":{"line":67,"column":7}}],"line":61},"3":{"loc":{"start":{"line":63,"column":13},"end":{"line":67,"column":7}},"type":"if","locations":[{"start":{"line":63,"column":13},"end":{"line":67,"column":7}},{"start":{"line":63,"column":13},"end":{"line":67,"column":7}}],"line":63},"4":{"loc":{"start":{"line":74,"column":4},"end":{"line":76,"column":5}},"type":"if","locations":[{"start":{"line":74,"column":4},"end":{"line":76,"column":5}},{"start":{"line":74,"column":4},"end":{"line":76,"column":5}}],"line":74},"5":{"loc":{"start":{"line":82,"column":31},"end":{"line":82,"column":40}},"type":"default-arg","locations":[{"start":{"line":82,"column":38},"end":{"line":82,"column":40}}],"line":82},"6":{"loc":{"start":{"line":91,"column":2},"end":{"line":101,"column":3}},"type":"if","locations":[{"start":{"line":91,"column":2},"end":{"line":101,"column":3}},{"start":{"line":91,"column":2},"end":{"line":101,"column":3}}],"line":91},"7":{"loc":{"start":{"line":119,"column":2},"end":{"line":127,"column":3}},"type":"if","locations":[{"start":{"line":119,"column":2},"end":{"line":127,"column":3}},{"start":{"line":119,"column":2},"end":{"line":127,"column":3}}],"line":119},"8":{"loc":{"start":{"line":120,"column":4},"end":{"line":122,"column":5}},"type":"if","locations":[{"start":{"line":120,"column":4},"end":{"line":122,"column":5}},{"start":{"line":120,"column":4},"end":{"line":122,"column":5}}],"line":120}},"s":{"0":3,"1":3,"2":0,"3":40,"4":40,"5":40,"6":52,"7":52,"8":52,"9":23,"10":23,"11":23,"12":23,"13":23,"14":29,"15":29,"16":1,"17":28,"18":23,"19":5,"20":29,"21":52,"22":35,"23":40,"24":17,"25":17,"26":17,"27":4,"28":5,"29":4,"30":4,"31":4,"32":13,"33":14,"34":11,"35":11,"36":11,"37":11,"38":8,"39":5,"40":8,"41":3,"42":6,"43":6,"44":6},"f":{"0":0,"1":40,"2":52,"3":17,"4":5,"5":14,"6":11,"7":11},"b":{"0":[0],"1":[23,29],"2":[1,28],"3":[23,5],"4":[35,17],"5":[0],"6":[4,13],"7":[8,3],"8":[5,3]},"_coverageSchema":"43e27e138ebf9cfc5966b082cf9a028302ed4184","hash":"d14a30f16c530fdecaf115469a3c256387342af1"} +,"/home/lalis/git/p5.js-web-editor/server/domain-objects/createDefaultFiles.js": {"path":"/home/lalis/git/p5.js-web-editor/server/domain-objects/createDefaultFiles.js","statementMap":{"0":{"start":{"line":1,"column":22},"end":{"line":7,"column":2}},"1":{"start":{"line":10,"column":2},"end":{"line":24,"column":1}},"2":{"start":{"line":27,"column":2},"end":{"line":34,"column":1}},"3":{"start":{"line":37,"column":2},"end":{"line":47,"column":4}}},"fnMap":{"0":{"name":"createDefaultFiles","decl":{"start":{"line":36,"column":24},"end":{"line":36,"column":42}},"loc":{"start":{"line":36,"column":45},"end":{"line":48,"column":1}},"line":36}},"branchMap":{},"s":{"0":3,"1":3,"2":3,"3":5},"f":{"0":5},"b":{},"_coverageSchema":"43e27e138ebf9cfc5966b082cf9a028302ed4184","hash":"d972311abf4c13044acd4b2f18c045cbd1bf941a"} +,"/home/lalis/git/p5.js-web-editor/server/models/project.js": {"path":"/home/lalis/git/p5.js-web-editor/server/models/project.js","statementMap":{"0":{"start":{"line":8,"column":19},"end":{"line":8,"column":27}},"1":{"start":{"line":10,"column":19},"end":{"line":20,"column":1}},"2":{"start":{"line":22,"column":0},"end":{"line":24,"column":3}},"3":{"start":{"line":23,"column":2},"end":{"line":23,"column":32}},"4":{"start":{"line":26,"column":0},"end":{"line":28,"column":3}},"5":{"start":{"line":30,"column":22},"end":{"line":40,"column":1}},"6":{"start":{"line":42,"column":0},"end":{"line":44,"column":3}},"7":{"start":{"line":43,"column":2},"end":{"line":43,"column":18}},"8":{"start":{"line":46,"column":0},"end":{"line":48,"column":3}},"9":{"start":{"line":50,"column":0},"end":{"line":58,"column":3}},"10":{"start":{"line":51,"column":18},"end":{"line":51,"column":22}},"11":{"start":{"line":53,"column":2},"end":{"line":55,"column":3}},"12":{"start":{"line":54,"column":4},"end":{"line":54,"column":46}},"13":{"start":{"line":57,"column":2},"end":{"line":57,"column":16}},"14":{"start":{"line":63,"column":0},"end":{"line":89,"column":2}},"15":{"start":{"line":64,"column":18},"end":{"line":64,"column":22}},"16":{"start":{"line":65,"column":22},"end":{"line":65,"column":46}},"17":{"start":{"line":67,"column":2},"end":{"line":88,"column":3}},"18":{"start":{"line":68,"column":25},"end":{"line":70,"column":13}},"19":{"start":{"line":72,"column":19},"end":{"line":75,"column":5}},"20":{"start":{"line":74,"column":44},"end":{"line":74,"column":49}},"21":{"start":{"line":77,"column":4},"end":{"line":79,"column":5}},"22":{"start":{"line":78,"column":6},"end":{"line":78,"column":23}},"23":{"start":{"line":81,"column":4},"end":{"line":81,"column":18}},"24":{"start":{"line":83,"column":4},"end":{"line":85,"column":5}},"25":{"start":{"line":84,"column":6},"end":{"line":84,"column":20}},"26":{"start":{"line":87,"column":4},"end":{"line":87,"column":14}}},"fnMap":{"0":{"name":"getFileId","decl":{"start":{"line":22,"column":38},"end":{"line":22,"column":47}},"loc":{"start":{"line":22,"column":50},"end":{"line":24,"column":1}},"line":22},"1":{"name":"getProjectId","decl":{"start":{"line":42,"column":41},"end":{"line":42,"column":53}},"loc":{"start":{"line":42,"column":56},"end":{"line":44,"column":1}},"line":42},"2":{"name":"generateSlug","decl":{"start":{"line":50,"column":35},"end":{"line":50,"column":47}},"loc":{"start":{"line":50,"column":54},"end":{"line":58,"column":1}},"line":50},"3":{"name":"isSlugUnique","decl":{"start":{"line":63,"column":52},"end":{"line":63,"column":64}},"loc":{"start":{"line":63,"column":69},"end":{"line":89,"column":1}},"line":63},"4":{"name":"(anonymous_4)","decl":{"start":{"line":74,"column":39},"end":{"line":74,"column":40}},"loc":{"start":{"line":74,"column":44},"end":{"line":74,"column":49}},"line":74}},"branchMap":{"0":{"loc":{"start":{"line":53,"column":2},"end":{"line":55,"column":3}},"type":"if","locations":[{"start":{"line":53,"column":2},"end":{"line":55,"column":3}},{"start":{"line":53,"column":2},"end":{"line":55,"column":3}}],"line":53},"1":{"loc":{"start":{"line":74,"column":22},"end":{"line":74,"column":56}},"type":"binary-expr","locations":[{"start":{"line":74,"column":22},"end":{"line":74,"column":50}},{"start":{"line":74,"column":54},"end":{"line":74,"column":56}}],"line":74},"2":{"loc":{"start":{"line":77,"column":4},"end":{"line":79,"column":5}},"type":"if","locations":[{"start":{"line":77,"column":4},"end":{"line":79,"column":5}},{"start":{"line":77,"column":4},"end":{"line":79,"column":5}}],"line":77},"3":{"loc":{"start":{"line":83,"column":4},"end":{"line":85,"column":5}},"type":"if","locations":[{"start":{"line":83,"column":4},"end":{"line":85,"column":5}},{"start":{"line":83,"column":4},"end":{"line":85,"column":5}}],"line":83}},"s":{"0":5,"1":5,"2":5,"3":0,"4":5,"5":5,"6":5,"7":3,"8":5,"9":5,"10":5,"11":5,"12":5,"13":5,"14":5,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0},"f":{"0":0,"1":3,"2":5,"3":0,"4":0},"b":{"0":[5,0],"1":[0,0],"2":[0,0],"3":[0,0]},"_coverageSchema":"43e27e138ebf9cfc5966b082cf9a028302ed4184","hash":"a33aaacd8058450eabf6f019099b2a8621c995ad"} +,"/home/lalis/git/p5.js-web-editor/server/models/user.js": {"path":"/home/lalis/git/p5.js-web-editor/server/models/user.js","statementMap":{"0":{"start":{"line":3,"column":15},"end":{"line":3,"column":39}},"1":{"start":{"line":5,"column":32},"end":{"line":9,"column":1}},"2":{"start":{"line":11,"column":19},"end":{"line":11,"column":27}},"3":{"start":{"line":13,"column":21},"end":{"line":17,"column":35}},"4":{"start":{"line":19,"column":0},"end":{"line":21,"column":3}},"5":{"start":{"line":20,"column":2},"end":{"line":20,"column":32}},"6":{"start":{"line":29,"column":2},"end":{"line":31,"column":4}},"7":{"start":{"line":34,"column":0},"end":{"line":36,"column":3}},"8":{"start":{"line":38,"column":0},"end":{"line":41,"column":3}},"9":{"start":{"line":43,"column":19},"end":{"line":71,"column":43}},"10":{"start":{"line":76,"column":0},"end":{"line":87,"column":3}},"11":{"start":{"line":77,"column":15},"end":{"line":77,"column":19}},"12":{"start":{"line":78,"column":2},"end":{"line":78,"column":54}},"13":{"start":{"line":78,"column":38},"end":{"line":78,"column":52}},"14":{"start":{"line":79,"column":2},"end":{"line":86,"column":5}},"15":{"start":{"line":80,"column":4},"end":{"line":80,"column":34}},"16":{"start":{"line":80,"column":15},"end":{"line":80,"column":32}},"17":{"start":{"line":81,"column":4},"end":{"line":85,"column":7}},"18":{"start":{"line":82,"column":6},"end":{"line":82,"column":46}},"19":{"start":{"line":82,"column":22},"end":{"line":82,"column":44}},"20":{"start":{"line":83,"column":6},"end":{"line":83,"column":27}},"21":{"start":{"line":84,"column":6},"end":{"line":84,"column":20}},"22":{"start":{"line":92,"column":0},"end":{"line":110,"column":3}},"23":{"start":{"line":93,"column":15},"end":{"line":93,"column":19}},"24":{"start":{"line":94,"column":2},"end":{"line":94,"column":53}},"25":{"start":{"line":94,"column":37},"end":{"line":94,"column":51}},"26":{"start":{"line":95,"column":15},"end":{"line":95,"column":20}},"27":{"start":{"line":96,"column":2},"end":{"line":108,"column":5}},"28":{"start":{"line":97,"column":4},"end":{"line":107,"column":5}},"29":{"start":{"line":98,"column":6},"end":{"line":98,"column":20}},"30":{"start":{"line":99,"column":6},"end":{"line":106,"column":9}},"31":{"start":{"line":100,"column":8},"end":{"line":100,"column":38}},"32":{"start":{"line":100,"column":19},"end":{"line":100,"column":36}},"33":{"start":{"line":101,"column":8},"end":{"line":105,"column":11}},"34":{"start":{"line":102,"column":10},"end":{"line":102,"column":50}},"35":{"start":{"line":102,"column":26},"end":{"line":102,"column":48}},"36":{"start":{"line":103,"column":10},"end":{"line":103,"column":29}},"37":{"start":{"line":104,"column":10},"end":{"line":104,"column":24}},"38":{"start":{"line":109,"column":2},"end":{"line":109,"column":29}},"39":{"start":{"line":109,"column":15},"end":{"line":109,"column":29}},"40":{"start":{"line":112,"column":0},"end":{"line":114,"column":3}},"41":{"start":{"line":113,"column":2},"end":{"line":113,"column":32}},"42":{"start":{"line":116,"column":0},"end":{"line":118,"column":3}},"43":{"start":{"line":123,"column":0},"end":{"line":128,"column":2}},"44":{"start":{"line":125,"column":2},"end":{"line":127,"column":5}},"45":{"start":{"line":126,"column":4},"end":{"line":126,"column":21}},"46":{"start":{"line":133,"column":0},"end":{"line":142,"column":2}},"47":{"start":{"line":134,"column":17},"end":{"line":134,"column":22}},"48":{"start":{"line":135,"column":2},"end":{"line":140,"column":5}},"49":{"start":{"line":136,"column":4},"end":{"line":139,"column":5}},"50":{"start":{"line":137,"column":6},"end":{"line":137,"column":22}},"51":{"start":{"line":138,"column":6},"end":{"line":138,"column":24}},"52":{"start":{"line":141,"column":2},"end":{"line":141,"column":65}},"53":{"start":{"line":141,"column":17},"end":{"line":141,"column":65}},"54":{"start":{"line":144,"column":0},"end":{"line":153,"column":2}},"55":{"start":{"line":145,"column":16},"end":{"line":151,"column":3}},"56":{"start":{"line":152,"column":2},"end":{"line":152,"column":36}},"57":{"start":{"line":155,"column":0},"end":{"line":155,"column":63}}},"fnMap":{"0":{"name":"getApiKeyId","decl":{"start":{"line":19,"column":40},"end":{"line":19,"column":51}},"loc":{"start":{"line":19,"column":54},"end":{"line":21,"column":1}},"line":19},"1":{"name":"apiKeyMetadata","decl":{"start":{"line":28,"column":9},"end":{"line":28,"column":23}},"loc":{"start":{"line":28,"column":43},"end":{"line":32,"column":1}},"line":28},"2":{"name":"checkPassword","decl":{"start":{"line":76,"column":32},"end":{"line":76,"column":45}},"loc":{"start":{"line":76,"column":52},"end":{"line":87,"column":1}},"line":76},"3":{"name":"(anonymous_3)","decl":{"start":{"line":79,"column":21},"end":{"line":79,"column":22}},"loc":{"start":{"line":79,"column":36},"end":{"line":86,"column":3}},"line":79},"4":{"name":"(anonymous_4)","decl":{"start":{"line":81,"column":43},"end":{"line":81,"column":44}},"loc":{"start":{"line":81,"column":63},"end":{"line":85,"column":5}},"line":81},"5":{"name":"checkApiKey","decl":{"start":{"line":92,"column":32},"end":{"line":92,"column":43}},"loc":{"start":{"line":92,"column":50},"end":{"line":110,"column":1}},"line":92},"6":{"name":"(anonymous_6)","decl":{"start":{"line":96,"column":23},"end":{"line":96,"column":24}},"loc":{"start":{"line":96,"column":30},"end":{"line":108,"column":3}},"line":96},"7":{"name":"(anonymous_7)","decl":{"start":{"line":99,"column":25},"end":{"line":99,"column":26}},"loc":{"start":{"line":99,"column":40},"end":{"line":106,"column":7}},"line":99},"8":{"name":"(anonymous_8)","decl":{"start":{"line":101,"column":45},"end":{"line":101,"column":46}},"loc":{"start":{"line":101,"column":65},"end":{"line":105,"column":9}},"line":101},"9":{"name":"idToString","decl":{"start":{"line":112,"column":38},"end":{"line":112,"column":48}},"loc":{"start":{"line":112,"column":51},"end":{"line":114,"column":1}},"line":112},"10":{"name":"comparePassword","decl":{"start":{"line":123,"column":46},"end":{"line":123,"column":61}},"loc":{"start":{"line":123,"column":85},"end":{"line":128,"column":1}},"line":123},"11":{"name":"(anonymous_11)","decl":{"start":{"line":125,"column":51},"end":{"line":125,"column":52}},"loc":{"start":{"line":125,"column":69},"end":{"line":127,"column":3}},"line":125},"12":{"name":"findMatchingKey","decl":{"start":{"line":133,"column":46},"end":{"line":133,"column":61}},"loc":{"start":{"line":133,"column":80},"end":{"line":142,"column":1}},"line":133},"13":{"name":"(anonymous_13)","decl":{"start":{"line":135,"column":23},"end":{"line":135,"column":24}},"loc":{"start":{"line":135,"column":30},"end":{"line":140,"column":3}},"line":135},"14":{"name":"findByMailOrName","decl":{"start":{"line":144,"column":47},"end":{"line":144,"column":63}},"loc":{"start":{"line":144,"column":71},"end":{"line":153,"column":1}},"line":144}},"branchMap":{"0":{"loc":{"start":{"line":78,"column":2},"end":{"line":78,"column":54}},"type":"if","locations":[{"start":{"line":78,"column":2},"end":{"line":78,"column":54}},{"start":{"line":78,"column":2},"end":{"line":78,"column":54}}],"line":78},"1":{"loc":{"start":{"line":80,"column":4},"end":{"line":80,"column":34}},"type":"if","locations":[{"start":{"line":80,"column":4},"end":{"line":80,"column":34}},{"start":{"line":80,"column":4},"end":{"line":80,"column":34}}],"line":80},"2":{"loc":{"start":{"line":82,"column":6},"end":{"line":82,"column":46}},"type":"if","locations":[{"start":{"line":82,"column":6},"end":{"line":82,"column":46}},{"start":{"line":82,"column":6},"end":{"line":82,"column":46}}],"line":82},"3":{"loc":{"start":{"line":94,"column":2},"end":{"line":94,"column":53}},"type":"if","locations":[{"start":{"line":94,"column":2},"end":{"line":94,"column":53}},{"start":{"line":94,"column":2},"end":{"line":94,"column":53}}],"line":94},"4":{"loc":{"start":{"line":97,"column":4},"end":{"line":107,"column":5}},"type":"if","locations":[{"start":{"line":97,"column":4},"end":{"line":107,"column":5}},{"start":{"line":97,"column":4},"end":{"line":107,"column":5}}],"line":97},"5":{"loc":{"start":{"line":100,"column":8},"end":{"line":100,"column":38}},"type":"if","locations":[{"start":{"line":100,"column":8},"end":{"line":100,"column":38}},{"start":{"line":100,"column":8},"end":{"line":100,"column":38}}],"line":100},"6":{"loc":{"start":{"line":102,"column":10},"end":{"line":102,"column":50}},"type":"if","locations":[{"start":{"line":102,"column":10},"end":{"line":102,"column":50}},{"start":{"line":102,"column":10},"end":{"line":102,"column":50}}],"line":102},"7":{"loc":{"start":{"line":109,"column":2},"end":{"line":109,"column":29}},"type":"if","locations":[{"start":{"line":109,"column":2},"end":{"line":109,"column":29}},{"start":{"line":109,"column":2},"end":{"line":109,"column":29}}],"line":109},"8":{"loc":{"start":{"line":136,"column":4},"end":{"line":139,"column":5}},"type":"if","locations":[{"start":{"line":136,"column":4},"end":{"line":139,"column":5}},{"start":{"line":136,"column":4},"end":{"line":139,"column":5}}],"line":136},"9":{"loc":{"start":{"line":141,"column":2},"end":{"line":141,"column":65}},"type":"if","locations":[{"start":{"line":141,"column":2},"end":{"line":141,"column":65}},{"start":{"line":141,"column":2},"end":{"line":141,"column":65}}],"line":141}},"s":{"0":6,"1":6,"2":6,"3":6,"4":6,"5":3,"6":1,"7":6,"8":6,"9":6,"10":6,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":6,"23":0,"24":0,"25":0,"26":0,"27":0,"28":0,"29":0,"30":0,"31":0,"32":0,"33":0,"34":0,"35":0,"36":0,"37":0,"38":0,"39":0,"40":6,"41":0,"42":6,"43":6,"44":0,"45":0,"46":6,"47":0,"48":0,"49":0,"50":0,"51":0,"52":0,"53":0,"54":6,"55":0,"56":0,"57":6},"f":{"0":3,"1":1,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0},"b":{"0":[0,0],"1":[0,0],"2":[0,0],"3":[0,0],"4":[0,0],"5":[0,0],"6":[0,0],"7":[0,0],"8":[0,0],"9":[0,0]},"_coverageSchema":"43e27e138ebf9cfc5966b082cf9a028302ed4184","hash":"dfccfda5673ec84b34281c5dc469bf8d7f8fdf70"} +,"/home/lalis/git/p5.js-web-editor/server/utils/createApplicationErrorClass.js": {"path":"/home/lalis/git/p5.js-web-editor/server/utils/createApplicationErrorClass.js","statementMap":{"0":{"start":{"line":7,"column":4},"end":{"line":7,"column":12}},"1":{"start":{"line":8,"column":4},"end":{"line":10,"column":5}},"2":{"start":{"line":9,"column":6},"end":{"line":9,"column":54}},"3":{"start":{"line":11,"column":4},"end":{"line":11,"column":35}},"4":{"start":{"line":12,"column":4},"end":{"line":12,"column":27}},"5":{"start":{"line":13,"column":4},"end":{"line":13,"column":27}},"6":{"start":{"line":26,"column":2},"end":{"line":32,"column":4}},"7":{"start":{"line":28,"column":6},"end":{"line":28,"column":23}},"8":{"start":{"line":30,"column":6},"end":{"line":30,"column":23}}},"fnMap":{"0":{"name":"(anonymous_0)","decl":{"start":{"line":6,"column":2},"end":{"line":6,"column":3}},"loc":{"start":{"line":6,"column":35},"end":{"line":14,"column":3}},"line":6},"1":{"name":"createApplicationErrorClass","decl":{"start":{"line":25,"column":24},"end":{"line":25,"column":51}},"loc":{"start":{"line":25,"column":58},"end":{"line":33,"column":1}},"line":25},"2":{"name":"(anonymous_2)","decl":{"start":{"line":27,"column":4},"end":{"line":27,"column":5}},"loc":{"start":{"line":27,"column":27},"end":{"line":31,"column":5}},"line":27}},"branchMap":{"0":{"loc":{"start":{"line":6,"column":23},"end":{"line":6,"column":33}},"type":"default-arg","locations":[{"start":{"line":6,"column":31},"end":{"line":6,"column":33}}],"line":6},"1":{"loc":{"start":{"line":8,"column":4},"end":{"line":10,"column":5}},"type":"if","locations":[{"start":{"line":8,"column":4},"end":{"line":10,"column":5}},{"start":{"line":8,"column":4},"end":{"line":10,"column":5}}],"line":8}},"s":{"0":13,"1":13,"2":13,"3":13,"4":13,"5":13,"6":8,"7":13,"8":13},"f":{"0":13,"1":8,"2":13},"b":{"0":[11],"1":[13,0]},"_coverageSchema":"43e27e138ebf9cfc5966b082cf9a028302ed4184","hash":"61df09b30b7047349005d720c6c5f46259c177cd"} +,"/home/lalis/git/p5.js-web-editor/server/utils/createId.js": {"path":"/home/lalis/git/p5.js-web-editor/server/utils/createId.js","statementMap":{"0":{"start":{"line":7,"column":2},"end":{"line":7,"column":34}}},"fnMap":{"0":{"name":"createId","decl":{"start":{"line":6,"column":24},"end":{"line":6,"column":32}},"loc":{"start":{"line":6,"column":35},"end":{"line":8,"column":1}},"line":6}},"branchMap":{},"s":{"0":10},"f":{"0":10},"b":{},"_coverageSchema":"43e27e138ebf9cfc5966b082cf9a028302ed4184","hash":"14c82f86e79ec993f102c8ec157621d1bced9eab"} +} diff --git a/coverage/lcov-report/base.css b/coverage/lcov-report/base.css new file mode 100644 index 00000000..f418035b --- /dev/null +++ b/coverage/lcov-report/base.css @@ -0,0 +1,224 @@ +body, html { + margin:0; padding: 0; + height: 100%; +} +body { + font-family: Helvetica Neue, Helvetica, Arial; + font-size: 14px; + color:#333; +} +.small { font-size: 12px; } +*, *:after, *:before { + -webkit-box-sizing:border-box; + -moz-box-sizing:border-box; + box-sizing:border-box; + } +h1 { font-size: 20px; margin: 0;} +h2 { font-size: 14px; } +pre { + font: 12px/1.4 Consolas, "Liberation Mono", Menlo, Courier, monospace; + margin: 0; + padding: 0; + -moz-tab-size: 2; + -o-tab-size: 2; + tab-size: 2; +} +a { color:#0074D9; text-decoration:none; } +a:hover { text-decoration:underline; } +.strong { font-weight: bold; } +.space-top1 { padding: 10px 0 0 0; } +.pad2y { padding: 20px 0; } +.pad1y { padding: 10px 0; } +.pad2x { padding: 0 20px; } +.pad2 { padding: 20px; } +.pad1 { padding: 10px; } +.space-left2 { padding-left:55px; } +.space-right2 { padding-right:20px; } +.center { text-align:center; } +.clearfix { display:block; } +.clearfix:after { + content:''; + display:block; + height:0; + clear:both; + visibility:hidden; + } +.fl { float: left; } +@media only screen and (max-width:640px) { + .col3 { width:100%; max-width:100%; } + .hide-mobile { display:none!important; } +} + +.quiet { + color: #7f7f7f; + color: rgba(0,0,0,0.5); +} +.quiet a { opacity: 0.7; } + +.fraction { + font-family: Consolas, 'Liberation Mono', Menlo, Courier, monospace; + font-size: 10px; + color: #555; + background: #E8E8E8; + padding: 4px 5px; + border-radius: 3px; + vertical-align: middle; +} + +div.path a:link, div.path a:visited { color: #333; } +table.coverage { + border-collapse: collapse; + margin: 10px 0 0 0; + padding: 0; +} + +table.coverage td { + margin: 0; + padding: 0; + vertical-align: top; +} +table.coverage td.line-count { + text-align: right; + padding: 0 5px 0 20px; +} +table.coverage td.line-coverage { + text-align: right; + padding-right: 10px; + min-width:20px; +} + +table.coverage td span.cline-any { + display: inline-block; + padding: 0 5px; + width: 100%; +} +.missing-if-branch { + display: inline-block; + margin-right: 5px; + border-radius: 3px; + position: relative; + padding: 0 4px; + background: #333; + color: yellow; +} + +.skip-if-branch { + display: none; + margin-right: 10px; + position: relative; + padding: 0 4px; + background: #ccc; + color: white; +} +.missing-if-branch .typ, .skip-if-branch .typ { + color: inherit !important; +} +.coverage-summary { + border-collapse: collapse; + width: 100%; +} +.coverage-summary tr { border-bottom: 1px solid #bbb; } +.keyline-all { border: 1px solid #ddd; } +.coverage-summary td, .coverage-summary th { padding: 10px; } +.coverage-summary tbody { border: 1px solid #bbb; } +.coverage-summary td { border-right: 1px solid #bbb; } +.coverage-summary td:last-child { border-right: none; } +.coverage-summary th { + text-align: left; + font-weight: normal; + white-space: nowrap; +} +.coverage-summary th.file { border-right: none !important; } +.coverage-summary th.pct { } +.coverage-summary th.pic, +.coverage-summary th.abs, +.coverage-summary td.pct, +.coverage-summary td.abs { text-align: right; } +.coverage-summary td.file { white-space: nowrap; } +.coverage-summary td.pic { min-width: 120px !important; } +.coverage-summary tfoot td { } + +.coverage-summary .sorter { + height: 10px; + width: 7px; + display: inline-block; + margin-left: 0.5em; + background: url(sort-arrow-sprite.png) no-repeat scroll 0 0 transparent; +} +.coverage-summary .sorted .sorter { + background-position: 0 -20px; +} +.coverage-summary .sorted-desc .sorter { + background-position: 0 -10px; +} +.status-line { height: 10px; } +/* yellow */ +.cbranch-no { background: yellow !important; color: #111; } +/* dark red */ +.red.solid, .status-line.low, .low .cover-fill { background:#C21F39 } +.low .chart { border:1px solid #C21F39 } +.highlighted, +.highlighted .cstat-no, .highlighted .fstat-no, .highlighted .cbranch-no{ + background: #C21F39 !important; +} +/* medium red */ +.cstat-no, .fstat-no, .cbranch-no, .cbranch-no { background:#F6C6CE } +/* light red */ +.low, .cline-no { background:#FCE1E5 } +/* light green */ +.high, .cline-yes { background:rgb(230,245,208) } +/* medium green */ +.cstat-yes { background:rgb(161,215,106) } +/* dark green */ +.status-line.high, .high .cover-fill { background:rgb(77,146,33) } +.high .chart { border:1px solid rgb(77,146,33) } +/* dark yellow (gold) */ +.status-line.medium, .medium .cover-fill { background: #f9cd0b; } +.medium .chart { border:1px solid #f9cd0b; } +/* light yellow */ +.medium { background: #fff4c2; } + +.cstat-skip { background: #ddd; color: #111; } +.fstat-skip { background: #ddd; color: #111 !important; } +.cbranch-skip { background: #ddd !important; color: #111; } + +span.cline-neutral { background: #eaeaea; } + +.coverage-summary td.empty { + opacity: .5; + padding-top: 4px; + padding-bottom: 4px; + line-height: 1; + color: #888; +} + +.cover-fill, .cover-empty { + display:inline-block; + height: 12px; +} +.chart { + line-height: 0; +} +.cover-empty { + background: white; +} +.cover-full { + border-right: none !important; +} +pre.prettyprint { + border: none !important; + padding: 0 !important; + margin: 0 !important; +} +.com { color: #999 !important; } +.ignore-none { color: #999; font-weight: normal; } + +.wrapper { + min-height: 100%; + height: auto !important; + height: 100%; + margin: 0 auto -48px; +} +.footer, .push { + height: 48px; +} diff --git a/coverage/lcov-report/block-navigation.js b/coverage/lcov-report/block-navigation.js new file mode 100644 index 00000000..c7ff5a5c --- /dev/null +++ b/coverage/lcov-report/block-navigation.js @@ -0,0 +1,79 @@ +/* eslint-disable */ +var jumpToCode = (function init() { + // Classes of code we would like to highlight in the file view + var missingCoverageClasses = ['.cbranch-no', '.cstat-no', '.fstat-no']; + + // Elements to highlight in the file listing view + var fileListingElements = ['td.pct.low']; + + // We don't want to select elements that are direct descendants of another match + var notSelector = ':not(' + missingCoverageClasses.join('):not(') + ') > '; // becomes `:not(a):not(b) > ` + + // Selecter that finds elements on the page to which we can jump + var selector = + fileListingElements.join(', ') + + ', ' + + notSelector + + missingCoverageClasses.join(', ' + notSelector); // becomes `:not(a):not(b) > a, :not(a):not(b) > b` + + // The NodeList of matching elements + var missingCoverageElements = document.querySelectorAll(selector); + + var currentIndex; + + function toggleClass(index) { + missingCoverageElements + .item(currentIndex) + .classList.remove('highlighted'); + missingCoverageElements.item(index).classList.add('highlighted'); + } + + function makeCurrent(index) { + toggleClass(index); + currentIndex = index; + missingCoverageElements.item(index).scrollIntoView({ + behavior: 'smooth', + block: 'center', + inline: 'center' + }); + } + + function goToPrevious() { + var nextIndex = 0; + if (typeof currentIndex !== 'number' || currentIndex === 0) { + nextIndex = missingCoverageElements.length - 1; + } else if (missingCoverageElements.length > 1) { + nextIndex = currentIndex - 1; + } + + makeCurrent(nextIndex); + } + + function goToNext() { + var nextIndex = 0; + + if ( + typeof currentIndex === 'number' && + currentIndex < missingCoverageElements.length - 1 + ) { + nextIndex = currentIndex + 1; + } + + makeCurrent(nextIndex); + } + + return function jump(event) { + switch (event.which) { + case 78: // n + case 74: // j + goToNext(); + break; + case 66: // b + case 75: // k + case 80: // p + goToPrevious(); + break; + } + }; +})(); +window.addEventListener('keydown', jumpToCode); diff --git a/coverage/lcov-report/client/__test__/mocks/fileMock.js.html b/coverage/lcov-report/client/__test__/mocks/fileMock.js.html new file mode 100644 index 00000000..05c24984 --- /dev/null +++ b/coverage/lcov-report/client/__test__/mocks/fileMock.js.html @@ -0,0 +1,82 @@ + + + + + + Code coverage report for client/__test__/mocks/fileMock.js + + + + + + + + +
+
+

All files / client/__test__/mocks fileMock.js

+
+ +
+ 100% + Statements + 1/1 +
+ + +
+ 100% + Branches + 0/0 +
+ + +
+ 100% + Functions + 0/0 +
+ + +
+ 100% + Lines + 1/1 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+
+
+

+
1 +22x + 
module.exports = 'test-file-stub';
+ 
+ +
+
+ + + + + + + + + \ No newline at end of file diff --git a/coverage/lcov-report/client/__test__/mocks/index.html b/coverage/lcov-report/client/__test__/mocks/index.html new file mode 100644 index 00000000..4e2c99d6 --- /dev/null +++ b/coverage/lcov-report/client/__test__/mocks/index.html @@ -0,0 +1,110 @@ + + + + + + Code coverage report for client/__test__/mocks + + + + + + + + +
+
+

All files client/__test__/mocks

+
+ +
+ 100% + Statements + 1/1 +
+ + +
+ 100% + Branches + 0/0 +
+ + +
+ 100% + Functions + 0/0 +
+ + +
+ 100% + Lines + 1/1 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+
+
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
FileStatementsBranchesFunctionsLines
fileMock.js +
+
100%1/1100%0/0100%0/0100%1/1
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/coverage/lcov-report/client/components/Nav.jsx.html b/coverage/lcov-report/client/components/Nav.jsx.html new file mode 100644 index 00000000..8c79c983 --- /dev/null +++ b/coverage/lcov-report/client/components/Nav.jsx.html @@ -0,0 +1,2425 @@ + + + + + + Code coverage report for client/components/Nav.jsx + + + + + + + + +
+
+

All files / client/components Nav.jsx

+
+ +
+ 38.85% + Statements + 54/139 +
+ + +
+ 28.79% + Branches + 19/66 +
+ + +
+ 15.91% + Functions + 7/44 +
+ + +
+ 38.85% + Lines + 54/139 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30 +31 +32 +33 +34 +35 +36 +37 +38 +39 +40 +41 +42 +43 +44 +45 +46 +47 +48 +49 +50 +51 +52 +53 +54 +55 +56 +57 +58 +59 +60 +61 +62 +63 +64 +65 +66 +67 +68 +69 +70 +71 +72 +73 +74 +75 +76 +77 +78 +79 +80 +81 +82 +83 +84 +85 +86 +87 +88 +89 +90 +91 +92 +93 +94 +95 +96 +97 +98 +99 +100 +101 +102 +103 +104 +105 +106 +107 +108 +109 +110 +111 +112 +113 +114 +115 +116 +117 +118 +119 +120 +121 +122 +123 +124 +125 +126 +127 +128 +129 +130 +131 +132 +133 +134 +135 +136 +137 +138 +139 +140 +141 +142 +143 +144 +145 +146 +147 +148 +149 +150 +151 +152 +153 +154 +155 +156 +157 +158 +159 +160 +161 +162 +163 +164 +165 +166 +167 +168 +169 +170 +171 +172 +173 +174 +175 +176 +177 +178 +179 +180 +181 +182 +183 +184 +185 +186 +187 +188 +189 +190 +191 +192 +193 +194 +195 +196 +197 +198 +199 +200 +201 +202 +203 +204 +205 +206 +207 +208 +209 +210 +211 +212 +213 +214 +215 +216 +217 +218 +219 +220 +221 +222 +223 +224 +225 +226 +227 +228 +229 +230 +231 +232 +233 +234 +235 +236 +237 +238 +239 +240 +241 +242 +243 +244 +245 +246 +247 +248 +249 +250 +251 +252 +253 +254 +255 +256 +257 +258 +259 +260 +261 +262 +263 +264 +265 +266 +267 +268 +269 +270 +271 +272 +273 +274 +275 +276 +277 +278 +279 +280 +281 +282 +283 +284 +285 +286 +287 +288 +289 +290 +291 +292 +293 +294 +295 +296 +297 +298 +299 +300 +301 +302 +303 +304 +305 +306 +307 +308 +309 +310 +311 +312 +313 +314 +315 +316 +317 +318 +319 +320 +321 +322 +323 +324 +325 +326 +327 +328 +329 +330 +331 +332 +333 +334 +335 +336 +337 +338 +339 +340 +341 +342 +343 +344 +345 +346 +347 +348 +349 +350 +351 +352 +353 +354 +355 +356 +357 +358 +359 +360 +361 +362 +363 +364 +365 +366 +367 +368 +369 +370 +371 +372 +373 +374 +375 +376 +377 +378 +379 +380 +381 +382 +383 +384 +385 +386 +387 +388 +389 +390 +391 +392 +393 +394 +395 +396 +397 +398 +399 +400 +401 +402 +403 +404 +405 +406 +407 +408 +409 +410 +411 +412 +413 +414 +415 +416 +417 +418 +419 +420 +421 +422 +423 +424 +425 +426 +427 +428 +429 +430 +431 +432 +433 +434 +435 +436 +437 +438 +439 +440 +441 +442 +443 +444 +445 +446 +447 +448 +449 +450 +451 +452 +453 +454 +455 +456 +457 +458 +459 +460 +461 +462 +463 +464 +465 +466 +467 +468 +469 +470 +471 +472 +473 +474 +475 +476 +477 +478 +479 +480 +481 +482 +483 +484 +485 +486 +487 +488 +489 +490 +491 +492 +493 +494 +495 +496 +497 +498 +499 +500 +501 +502 +503 +504 +505 +506 +507 +508 +509 +510 +511 +512 +513 +514 +515 +516 +517 +518 +519 +520 +521 +522 +523 +524 +525 +526 +527 +528 +529 +530 +531 +532 +533 +534 +535 +536 +537 +538 +539 +540 +541 +542 +543 +544 +545 +546 +547 +548 +549 +550 +551 +552 +553 +554 +555 +556 +557 +558 +559 +560 +561 +562 +563 +564 +565 +566 +567 +568 +569 +570 +571 +572 +573 +574 +575 +576 +577 +578 +579 +580 +581 +582 +583 +584 +585 +586 +587 +588 +589 +590 +591 +592 +593 +594 +595 +596 +597 +598 +599 +600 +601 +602 +603 +604 +605 +606 +607 +608 +609 +610 +611 +612 +613 +614 +615 +616 +617 +618 +619 +620 +621 +622 +623 +624 +625 +626 +627 +628 +629 +630 +631 +632 +633 +634 +635 +636 +637 +638 +639 +640 +641 +642 +643 +644 +645 +646 +647 +648 +649 +650 +651 +652 +653 +654 +655 +656 +657 +658 +659 +660 +661 +662 +663 +664 +665 +666 +667 +668 +669 +670 +671 +672 +673 +674 +675 +676 +677 +678 +679 +680 +681 +682 +683 +684 +685 +686 +687 +688 +689 +690 +691 +692 +693 +694 +695 +696 +697 +698 +699 +700 +701 +702 +703 +704 +705 +706 +707 +708 +709 +710 +711 +712 +713 +714 +715 +716 +717 +718 +719 +720 +721 +722 +723 +724 +725 +726 +727 +728 +729 +730 +731 +732 +733 +734 +735 +736 +737 +738 +739 +740 +741 +742 +743 +744 +745 +746 +747 +748 +749 +750 +751 +752 +753 +754 +755 +756 +757 +758 +759 +760 +761 +762 +763 +764 +765 +766 +767 +768 +769 +770 +771 +772 +773 +774 +775 +776 +777 +778 +779 +780 +781 +782 +783  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +1x +1x +  +1x +  +  +  +2x +2x +  +  +2x +2x +2x +2x +2x +2x +2x +2x +2x +2x +2x +2x +2x +2x +2x +2x +2x +2x +2x +2x +2x +2x +2x +2x +2x +2x +2x +2x +2x +2x +2x +2x +2x +  +  +  +2x +2x +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +2x +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +2x +2x +  +2x +  +2x +  +  +  +2x +  +  +  +2x +  +  +  +  +2x +  +  +  +  +2x +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +2x +1x +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +1x +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +1x +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +1x +  +  +  +  +  +  +  +  +  + 
import PropTypes from 'prop-types';
+import React from 'react';
+import { connect } from 'react-redux';
+import { withRouter } from 'react-router';
+import { Link } from 'react-router';
+import InlineSVG from 'react-inlinesvg';
+import classNames from 'classnames';
+import * as IDEActions from '../modules/IDE/actions/ide';
+import * as toastActions from '../modules/IDE/actions/toast';
+import * as projectActions from '../modules/IDE/actions/project';
+import { setAllAccessibleOutput } from '../modules/IDE/actions/preferences';
+import { logoutUser } from '../modules/User/actions';
+ 
+import { metaKeyName, } from '../utils/metaKey';
+import caretLeft from '../images/left-arrow.svg';
+ 
+const triangleUrl = require('../images/down-filled-triangle.svg');
+const logoUrl = require('../images/p5js-logo-small.svg');
+ 
+const __process = (typeof global !== 'undefined' ? global : window).process;
+ 
+class Nav extends React.PureComponent {
+  constructor(props) {
+    super(props);
+    this.state = {
+      dropdownOpen: 'none'
+    };
+    this.handleFocus = this.handleFocus.bind(this);
+    this.handleBlur = this.handleBlur.bind(this);
+    this.clearHideTimeout = this.clearHideTimeout.bind(this);
+    this.handleClick = this.handleClick.bind(this);
+    this.handleClickOutside = this.handleClickOutside.bind(this);
+    this.handleSave = this.handleSave.bind(this);
+    this.handleNew = this.handleNew.bind(this);
+    this.handleDuplicate = this.handleDuplicate.bind(this);
+    this.handleShare = this.handleShare.bind(this);
+    this.handleDownload = this.handleDownload.bind(this);
+    this.handleFind = this.handleFind.bind(this);
+    this.handleAddFile = this.handleAddFile.bind(this);
+    this.handleAddFolder = this.handleAddFolder.bind(this);
+    this.handleFindNext = this.handleFindNext.bind(this);
+    this.handleRun = this.handleRun.bind(this);
+    this.handleFindPrevious = this.handleFindPrevious.bind(this);
+    this.handleStop = this.handleStop.bind(this);
+    this.handleStartAccessible = this.handleStartAccessible.bind(this);
+    this.handleStopAccessible = this.handleStopAccessible.bind(this);
+    this.handleKeyboardShortcuts = this.handleKeyboardShortcuts.bind(this);
+    this.handleLogout = this.handleLogout.bind(this);
+    this.toggleDropdownForFile = this.toggleDropdown.bind(this, 'file');
+    this.handleFocusForFile = this.handleFocus.bind(this, 'file');
+    this.setDropdownForNone = this.setDropdown.bind(this, 'none');
+    this.toggleDropdownForEdit = this.toggleDropdown.bind(this, 'edit');
+    this.handleFocusForEdit = this.handleFocus.bind(this, 'edit');
+    this.toggleDropdownForSketch = this.toggleDropdown.bind(this, 'sketch');
+    this.handleFocusForSketch = this.handleFocus.bind(this, 'sketch');
+    this.toggleDropdownForHelp = this.toggleDropdown.bind(this, 'help');
+    this.handleFocusForHelp = this.handleFocus.bind(this, 'help');
+    this.toggleDropdownForAccount = this.toggleDropdown.bind(this, 'account');
+    this.handleFocusForAccount = this.handleFocus.bind(this, 'account');
+    this.closeDropDown = this.closeDropDown.bind(this);
+  }
+ 
+  componentDidMount() {
+    document.addEventListener('mousedown', this.handleClick, false);
+    document.addEventListener('keydown', this.closeDropDown, false);
+  }
+  componentWillUnmount() {
+    document.removeEventListener('mousedown', this.handleClick, false);
+    document.removeEventListener('keydown', this.closeDropDown, false);
+  }
+ 
+  setDropdown(dropdown) {
+    this.setState({
+      dropdownOpen: dropdown
+    });
+  }
+ 
+  closeDropDown(e) {
+    if (e.keyCode === 27) {
+      this.setDropdown('none');
+    }
+  }
+ 
+  handleClick(e) {
+    if (!this.node) {
+      return;
+    }
+    if (this.node && this.node.contains(e.target)) {
+      return;
+    }
+ 
+    this.handleClickOutside();
+  }
+ 
+  handleNew() {
+    const { unsavedChanges, warnIfUnsavedChanges } = this.props;
+    if (!unsavedChanges) {
+      this.props.showToast(1500);
+      this.props.setToastText('Opened new sketch.');
+      this.props.newProject();
+    } else if (warnIfUnsavedChanges && warnIfUnsavedChanges()) {
+      this.props.showToast(1500);
+      this.props.setToastText('Opened new sketch.');
+      this.props.newProject();
+    }
+    this.setDropdown('none');
+  }
+ 
+  handleSave() {
+    if (this.props.user.authenticated) {
+      this.props.saveProject(this.props.cmController.getContent());
+    } else {
+      this.props.showErrorModal('forceAuthentication');
+    }
+    this.setDropdown('none');
+  }
+ 
+  handleFind() {
+    this.props.cmController.showFind();
+    this.setDropdown('none');
+  }
+ 
+  handleFindNext() {
+    this.props.cmController.findNext();
+    this.setDropdown('none');
+  }
+ 
+  handleFindPrevious() {
+    this.props.cmController.findPrev();
+    this.setDropdown('none');
+  }
+ 
+  handleAddFile() {
+    this.props.newFile(this.props.rootFile.id);
+    this.setDropdown('none');
+  }
+ 
+  handleAddFolder() {
+    this.props.newFolder(this.props.rootFile.id);
+    this.setDropdown('none');
+  }
+ 
+  handleRun() {
+    this.props.startSketch();
+    this.setDropdown('none');
+  }
+ 
+  handleStop() {
+    this.props.stopSketch();
+    this.setDropdown('none');
+  }
+ 
+  handleStartAccessible() {
+    this.props.setAllAccessibleOutput(true);
+    this.setDropdown('none');
+  }
+ 
+  handleStopAccessible() {
+    this.props.setAllAccessibleOutput(false);
+    this.setDropdown('none');
+  }
+ 
+  handleKeyboardShortcuts() {
+    this.props.showKeyboardShortcutModal();
+    this.setDropdown('none');
+  }
+ 
+  handleLogout() {
+    this.props.logoutUser();
+    this.setDropdown('none');
+  }
+ 
+  handleDownload() {
+    this.props.autosaveProject();
+    projectActions.exportProjectAsZip(this.props.project.id);
+    this.setDropdown('none');
+  }
+ 
+  handleDuplicate() {
+    this.props.cloneProject();
+    this.setDropdown('none');
+  }
+ 
+  handleShare() {
+    const { username } = this.props.params;
+    this.props.showShareModal(this.props.project.id, this.props.project.name, username);
+    this.setDropdown('none');
+  }
+ 
+  handleClickOutside() {
+    this.setState({
+      dropdownOpen: 'none'
+    });
+  }
+ 
+  toggleDropdown(dropdown) {
+    if (this.state.dropdownOpen === 'none') {
+      this.setState({
+        dropdownOpen: dropdown
+      });
+    } else {
+      this.setState({
+        dropdownOpen: 'none'
+      });
+    }
+  }
+ 
+  isUserOwner() {
+    return this.props.project.owner && this.props.project.owner.id === this.props.user.id;
+  }
+ 
+  handleFocus(dropdown) {
+    this.clearHideTimeout();
+    this.setDropdown(dropdown);
+  }
+ 
+  clearHideTimeout() {
+    if (this.timer) {
+      clearTimeout(this.timer);
+      this.timer = null;
+    }
+  }
+ 
+  handleBlur() {
+    this.timer = setTimeout(this.setDropdown.bind(this, 'none'), 10);
+  }
+ 
+  renderDashboardMenu(navDropdownState) {
+    return (
+      <ul className="nav__items-left" title="project-menu">
+        <li className="nav__item-logo">
+          <InlineSVG src={logoUrl} alt="p5.js logo" className="svg__logo" />
+        </li>
+        <li className="nav__item nav__item--no-icon">
+          <Link to="/" className="nav__back-link">
+            <InlineSVG src={caretLeft} className="nav__back-icon" />
+            <span className="nav__item-header">
+              Back to Editor
+            </span>
+          </Link>
+        </li>
+      </ul>
+    );
+  }
+ 
+  renderProjectMenu(navDropdownState) {
+    return (
+      <ul className="nav__items-left" title="project-menu">
+        <li className="nav__item-logo">
+          <InlineSVG src={logoUrl} alt="p5.js logo" className="svg__logo" />
+        </li>
+        <li className={navDropdownState.file}>
+          <button
+            onClick={this.toggleDropdownForFile}
+            onBlur={this.handleBlur}
+            onFocus={this.clearHideTimeout}
+            onMouseOver={() => {
+              if (this.state.dropdownOpen !== 'none') {
+                this.setDropdown('file');
+              }
+            }}
+          >
+            <span className="nav__item-header">File</span>
+            <InlineSVG className="nav__item-header-triangle" src={triangleUrl} />
+          </button>
+          <ul className="nav__dropdown">
+            <li className="nav__dropdown-item">
+              <button
+                onClick={this.handleNew}
+                onFocus={this.handleFocusForFile}
+                onBlur={this.handleBlur}
+              >
+                New
+              </button>
+            </li>
+            { __process.env.LOGIN_ENABLED && (!this.props.project.owner || this.isUserOwner()) &&
+            <li className="nav__dropdown-item">
+              <button
+                onClick={this.handleSave}
+                onFocus={this.handleFocusForFile}
+                onBlur={this.handleBlur}
+              >
+                Save
+                <span className="nav__keyboard-shortcut">{metaKeyName}+s</span>
+              </button>
+            </li> }
+            { this.props.project.id && this.props.user.authenticated &&
+            <li className="nav__dropdown-item">
+              <button
+                onClick={this.handleDuplicate}
+                onFocus={this.handleFocusForFile}
+                onBlur={this.handleBlur}
+              >
+                Duplicate
+              </button>
+            </li> }
+            { this.props.project.id &&
+            <li className="nav__dropdown-item">
+              <button
+                onClick={this.handleShare}
+                onFocus={this.handleFocusForFile}
+                onBlur={this.handleBlur}
+              >
+                Share
+              </button>
+            </li> }
+            { this.props.project.id &&
+            <li className="nav__dropdown-item">
+              <button
+                onClick={this.handleDownload}
+                onFocus={this.handleFocusForFile}
+                onBlur={this.handleBlur}
+              >
+                Download
+              </button>
+            </li> }
+            { this.props.user.authenticated &&
+            <li className="nav__dropdown-item">
+              <Link
+                to={`/${this.props.user.username}/sketches`}
+                onFocus={this.handleFocusForFile}
+                onBlur={this.handleBlur}
+                onClick={this.setDropdownForNone}
+              >
+                Open
+              </Link>
+            </li> }
+            {__process.env.UI_COLLECTIONS_ENABLED &&
+              this.props.user.authenticated &&
+              this.props.project.id &&
+              <li className="nav__dropdown-item">
+                <Link
+                  to={`/${this.props.user.username}/sketches/${this.props.project.id}/add-to-collection`}
+                  onFocus={this.handleFocusForFile}
+                  onBlur={this.handleBlur}
+                  onClick={this.setDropdownForNone}
+                >
+                  Add to Collection
+                </Link>
+              </li>}
+            { __process.env.EXAMPLES_ENABLED &&
+            <li className="nav__dropdown-item">
+              <Link
+                to="/p5/sketches"
+                onFocus={this.handleFocusForFile}
+                onBlur={this.handleBlur}
+                onClick={this.setDropdownForNone}
+              >
+                Examples
+              </Link>
+            </li> }
+          </ul>
+        </li>
+        <li className={navDropdownState.edit}>
+          <button
+            onClick={this.toggleDropdownForEdit}
+            onBlur={this.handleBlur}
+            onFocus={this.clearHideTimeout}
+            onMouseOver={() => {
+              if (this.state.dropdownOpen !== 'none') {
+                this.setDropdown('edit');
+              }
+            }}
+          >
+            <span className="nav__item-header">Edit</span>
+            <InlineSVG className="nav__item-header-triangle" src={triangleUrl} />
+          </button>
+          <ul className="nav__dropdown" >
+            <li className="nav__dropdown-item">
+              <button
+                onClick={() => {
+                  this.props.cmController.tidyCode();
+                  this.setDropdown('none');
+                }}
+                onFocus={this.handleFocusForEdit}
+                onBlur={this.handleBlur}
+              >
+                Tidy Code
+                <span className="nav__keyboard-shortcut">{'\u21E7'}+Tab</span>
+              </button>
+            </li>
+            <li className="nav__dropdown-item">
+              <button
+                onClick={this.handleFind}
+                onFocus={this.handleFocusForEdit}
+                onBlur={this.handleBlur}
+              >
+                Find
+                <span className="nav__keyboard-shortcut">{metaKeyName}+F</span>
+              </button>
+            </li>
+            <li className="nav__dropdown-item">
+              <button
+                onClick={this.handleFindNext}
+                onFocus={this.handleFocusForEdit}
+                onBlur={this.handleBlur}
+              >
+                Find Next
+                <span className="nav__keyboard-shortcut">{metaKeyName}+G</span>
+              </button>
+            </li>
+            <li className="nav__dropdown-item">
+              <button
+                onClick={this.handleFindPrevious}
+                onFocus={this.handleFocusForEdit}
+                onBlur={this.handleBlur}
+              >
+                Find Previous
+                <span className="nav__keyboard-shortcut">{'\u21E7'}+{metaKeyName}+G</span>
+              </button>
+            </li>
+          </ul>
+        </li>
+        <li className={navDropdownState.sketch}>
+          <button
+            onClick={this.toggleDropdownForSketch}
+            onBlur={this.handleBlur}
+            onFocus={this.clearHideTimeout}
+            onMouseOver={() => {
+              if (this.state.dropdownOpen !== 'none') {
+                this.setDropdown('sketch');
+              }
+            }}
+          >
+            <span className="nav__item-header">Sketch</span>
+            <InlineSVG className="nav__item-header-triangle" src={triangleUrl} />
+          </button>
+          <ul className="nav__dropdown">
+            <li className="nav__dropdown-item">
+              <button
+                onClick={this.handleAddFile}
+                onFocus={this.handleFocusForSketch}
+                onBlur={this.handleBlur}
+              >
+                Add File
+              </button>
+            </li>
+            <li className="nav__dropdown-item">
+              <button
+                onClick={this.handleAddFolder}
+                onFocus={this.handleFocusForSketch}
+                onBlur={this.handleBlur}
+              >
+                Add Folder
+              </button>
+            </li>
+            <li className="nav__dropdown-item">
+              <button
+                onClick={this.handleRun}
+                onFocus={this.handleFocusForSketch}
+                onBlur={this.handleBlur}
+              >
+                Run
+                <span className="nav__keyboard-shortcut">{metaKeyName}+Enter</span>
+              </button>
+            </li>
+            <li className="nav__dropdown-item">
+              <button
+                onClick={this.handleStop}
+                onFocus={this.handleFocusForSketch}
+                onBlur={this.handleBlur}
+              >
+                Stop
+                <span className="nav__keyboard-shortcut">{'\u21E7'}+{metaKeyName}+Enter</span>
+              </button>
+            </li>
+            {/* <li className="nav__dropdown-item">
+              <button
+                onClick={this.handleStartAccessible}
+                onFocus={this.handleFocusForSketch}
+                onBlur={this.handleBlur}
+              >
+                Start Accessible
+                <span className="nav__keyboard-shortcut">{'\u21E7'}+{metaKeyName}+1</span>
+              </button>
+            </li>
+            <li className="nav__dropdown-item">
+              <button
+                onClick={this.handleStopAccessible}
+                onFocus={this.handleFocusForSketch}
+                onBlur={this.handleBlur}
+              >
+                Stop Accessible
+                <span className="nav__keyboard-shortcut">{'\u21E7'}+{metaKeyName}+2</span>
+              </button>
+            </li> */}
+          </ul>
+        </li>
+        <li className={navDropdownState.help}>
+          <button
+            onClick={this.toggleDropdownForHelp}
+            onBlur={this.handleBlur}
+            onFocus={this.clearHideTimeout}
+            onMouseOver={() => {
+              if (this.state.dropdownOpen !== 'none') {
+                this.setDropdown('help');
+              }
+            }}
+          >
+            <span className="nav__item-header">Help</span>
+            <InlineSVG className="nav__item-header-triangle" src={triangleUrl} />
+          </button>
+          <ul className="nav__dropdown">
+            <li className="nav__dropdown-item">
+              <button
+                onFocus={this.handleFocusForHelp}
+                onBlur={this.handleBlur}
+                onClick={this.handleKeyboardShortcuts}
+              >
+                Keyboard Shortcuts
+              </button>
+            </li>
+            <li className="nav__dropdown-item">
+              <a
+                href="https://p5js.org/reference/"
+                target="_blank"
+                rel="noopener noreferrer"
+                onFocus={this.handleFocusForHelp}
+                onBlur={this.handleBlur}
+                onClick={this.setDropdownForNone}
+              >Reference
+              </a>
+            </li>
+            <li className="nav__dropdown-item">
+              <Link
+                to="/about"
+                onFocus={this.handleFocusForHelp}
+                onBlur={this.handleBlur}
+                onClick={this.setDropdownForNone}
+              >
+                About
+              </Link>
+            </li>
+          </ul>
+        </li>
+      </ul>
+    );
+  }
+ 
+  renderUnauthenticatedUserMenu(navDropdownState) {
+    return (
+      <ul className="nav__items-right" title="user-menu">
+        <li className="nav__item">
+          <Link to="/login">
+            <span className="nav__item-header">Log in</span>
+          </Link>
+        </li>
+        <span className="nav__item-spacer">or</span>
+        <li className="nav__item">
+          <Link to="/signup">
+            <span className="nav__item-header">Sign up</span>
+          </Link>
+        </li>
+      </ul>
+    );
+  }
+ 
+  renderAuthenticatedUserMenu(navDropdownState) {
+    return (
+      <ul className="nav__items-right" title="user-menu">
+        <li className="nav__item">
+          <span>Hello, {this.props.user.username}!</span>
+        </li>
+        <span className="nav__item-spacer">|</span>
+        <li className={navDropdownState.account}>
+          <button
+            className="nav__item-header"
+            onClick={this.toggleDropdownForAccount}
+            onBlur={this.handleBlur}
+            onFocus={this.clearHideTimeout}
+            onMouseOver={() => {
+              if (this.state.dropdownOpen !== 'none') {
+                this.setDropdown('account');
+              }
+            }}
+          >
+            My Account
+            <InlineSVG className="nav__item-header-triangle" src={triangleUrl} />
+          </button>
+          <ul className="nav__dropdown">
+            <li className="nav__dropdown-item">
+              <Link
+                to={`/${this.props.user.username}/sketches`}
+                onFocus={this.handleFocusForAccount}
+                onBlur={this.handleBlur}
+                onClick={this.setDropdownForNone}
+              >
+                My sketches
+              </Link>
+            </li>
+            {__process.env.UI_COLLECTIONS_ENABLED &&
+              <li className="nav__dropdown-item">
+                <Link
+                  to={`/${this.props.user.username}/collections`}
+                  onFocus={this.handleFocusForAccount}
+                  onBlur={this.handleBlur}
+                  onClick={this.setDropdownForNone}
+                >
+                  My collections
+                </Link>
+              </li>
+            }
+            <li className="nav__dropdown-item">
+              <Link
+                to={`/${this.props.user.username}/assets`}
+                onFocus={this.handleFocusForAccount}
+                onBlur={this.handleBlur}
+                onClick={this.setDropdownForNone}
+              >
+                My assets
+              </Link>
+            </li>
+            <li className="nav__dropdown-item">
+              <Link
+                to="/account"
+                onFocus={this.handleFocusForAccount}
+                onBlur={this.handleBlur}
+                onClick={this.setDropdownForNone}
+              >
+                Settings
+              </Link>
+            </li>
+            <li className="nav__dropdown-item">
+              <button
+                onClick={this.handleLogout}
+                onFocus={this.handleFocusForAccount}
+                onBlur={this.handleBlur}
+              >
+                Log out
+              </button>
+            </li>
+          </ul>
+        </li>
+      </ul>
+    );
+  }
+ 
+  renderUserMenu(navDropdownState) {
+    const isLoginEnabled = __process.env.LOGIN_ENABLED;
+    const isAuthenticated = this.props.user.authenticated;
+ 
+    Iif (isLoginEnabled && isAuthenticated) {
+      return this.renderAuthenticatedUserMenu(navDropdownState);
+    } else Iif (isLoginEnabled && !isAuthenticated) {
+      return this.renderUnauthenticatedUserMenu(navDropdownState);
+    }
+ 
+    return null;
+  }
+ 
+  renderLeftLayout(navDropdownState) {
+    switch (this.props.layout) {
+      case 'dashboard':
+        return this.renderDashboardMenu(navDropdownState);
+      case 'project':
+      default:
+        return this.renderProjectMenu(navDropdownState);
+    }
+  }
+ 
+  render() {
+    const navDropdownState = {
+      file: classNames({
+        'nav__item': true,
+        'nav__item--open': this.state.dropdownOpen === 'file'
+      }),
+      edit: classNames({
+        'nav__item': true,
+        'nav__item--open': this.state.dropdownOpen === 'edit'
+      }),
+      sketch: classNames({
+        'nav__item': true,
+        'nav__item--open': this.state.dropdownOpen === 'sketch'
+      }),
+      help: classNames({
+        'nav__item': true,
+        'nav__item--open': this.state.dropdownOpen === 'help'
+      }),
+      account: classNames({
+        'nav__item': true,
+        'nav__item--open': this.state.dropdownOpen === 'account'
+      })
+    };
+ 
+    return (
+      <nav className="nav" title="main-navigation" ref={(node) => { this.node = node; }}>
+        {this.renderLeftLayout(navDropdownState)}
+        {this.renderUserMenu(navDropdownState)}
+        {/*
+        <div className="nav__announce">
+          This is a preview version of the editor, that has not yet been officially released.
+          It is in development, you can report bugs <a
+            href="https://github.com/processing/p5.js-web-editor/issues"
+            target="_blank"
+            rel="noopener noreferrer"
+          >here</a>.
+          Please use with caution.
+        </div>
+      */}
+      </nav>
+    );
+  }
+}
+ 
+Nav.propTypes = {
+  newProject: PropTypes.func.isRequired,
+  showToast: PropTypes.func.isRequired,
+  setToastText: PropTypes.func.isRequired,
+  saveProject: PropTypes.func.isRequired,
+  autosaveProject: PropTypes.func.isRequired,
+  cloneProject: PropTypes.func.isRequired,
+  user: PropTypes.shape({
+    authenticated: PropTypes.bool.isRequired,
+    username: PropTypes.string,
+    id: PropTypes.string
+  }).isRequired,
+  project: PropTypes.shape({
+    id: PropTypes.string,
+    name: PropTypes.string,
+    owner: PropTypes.shape({
+      id: PropTypes.string
+    })
+  }),
+  logoutUser: PropTypes.func.isRequired,
+  showShareModal: PropTypes.func.isRequired,
+  showErrorModal: PropTypes.func.isRequired,
+  unsavedChanges: PropTypes.bool.isRequired,
+  warnIfUnsavedChanges: PropTypes.func,
+  showKeyboardShortcutModal: PropTypes.func.isRequired,
+  cmController: PropTypes.shape({
+    tidyCode: PropTypes.func,
+    showFind: PropTypes.func,
+    findNext: PropTypes.func,
+    findPrev: PropTypes.func,
+    getContent: PropTypes.func
+  }),
+  startSketch: PropTypes.func.isRequired,
+  stopSketch: PropTypes.func.isRequired,
+  setAllAccessibleOutput: PropTypes.func.isRequired,
+  newFile: PropTypes.func.isRequired,
+  newFolder: PropTypes.func.isRequired,
+  layout: PropTypes.oneOf(['dashboard', 'project']),
+  rootFile: PropTypes.shape({
+    id: PropTypes.string.isRequired
+  }).isRequired,
+  params: PropTypes.shape({
+    username: PropTypes.string
+  })
+};
+ 
+Nav.defaultProps = {
+  project: {
+    id: undefined,
+    owner: undefined
+  },
+  cmController: {},
+  layout: 'project',
+  warnIfUnsavedChanges: undefined,
+  params: {
+    username: undefined
+  }
+};
+ 
+function mapStateToProps(state) {
+  return {
+    project: state.project,
+    user: state.user,
+    unsavedChanges: state.ide.unsavedChanges,
+    rootFile: state.files.filter(file => file.name === 'root')[0]
+  };
+}
+ 
+const mapDispatchToProps = {
+  ...IDEActions,
+  ...projectActions,
+  ...toastActions,
+  logoutUser,
+  setAllAccessibleOutput
+};
+ 
+export default withRouter(connect(mapStateToProps, mapDispatchToProps)(Nav));
+export { Nav as NavComponent };
+ 
+ +
+
+ + + + + + + + + \ No newline at end of file diff --git a/coverage/lcov-report/client/components/index.html b/coverage/lcov-report/client/components/index.html new file mode 100644 index 00000000..5459627f --- /dev/null +++ b/coverage/lcov-report/client/components/index.html @@ -0,0 +1,110 @@ + + + + + + Code coverage report for client/components + + + + + + + + +
+
+

All files client/components

+
+ +
+ 38.85% + Statements + 54/139 +
+ + +
+ 28.79% + Branches + 19/66 +
+ + +
+ 15.91% + Functions + 7/44 +
+ + +
+ 38.85% + Lines + 54/139 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+
+
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
FileStatementsBranchesFunctionsLines
Nav.jsx +
+
38.85%54/13928.79%19/6615.91%7/4438.85%54/139
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/coverage/lcov-report/client/constants.js.html b/coverage/lcov-report/client/constants.js.html new file mode 100644 index 00000000..2c4bc15d --- /dev/null +++ b/coverage/lcov-report/client/constants.js.html @@ -0,0 +1,511 @@ + + + + + + Code coverage report for client/constants.js + + + + + + + + +
+
+

All files / client constants.js

+
+ +
+ 100% + Statements + 109/109 +
+ + +
+ 100% + Branches + 0/0 +
+ + +
+ 100% + Functions + 0/0 +
+ + +
+ 100% + Lines + 109/109 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30 +31 +32 +33 +34 +35 +36 +37 +38 +39 +40 +41 +42 +43 +44 +45 +46 +47 +48 +49 +50 +51 +52 +53 +54 +55 +56 +57 +58 +59 +60 +61 +62 +63 +64 +65 +66 +67 +68 +69 +70 +71 +72 +73 +74 +75 +76 +77 +78 +79 +80 +81 +82 +83 +84 +85 +86 +87 +88 +89 +90 +91 +92 +93 +94 +95 +96 +97 +98 +99 +100 +101 +102 +103 +104 +105 +106 +107 +108 +109 +110 +111 +112 +113 +114 +115 +116 +117 +118 +119 +120 +121 +122 +123 +124 +125 +126 +127 +128 +129 +130 +131 +132 +133 +134 +135 +136 +137 +138 +139 +140 +141 +142 +143 +144 +145  +  +2x +2x +  +2x +2x +  +2x +2x +  +2x +2x +2x +2x +  +2x +2x +2x +  +2x +  +2x +2x +  +2x +2x +  +2x +2x +2x +2x +2x +2x +  +2x +2x +  +2x +2x +2x +  +2x +2x +2x +  +2x +  +2x +2x +2x +2x +2x +  +2x +2x +  +2x +2x +2x +2x +  +2x +2x +  +2x +2x +  +2x +2x +2x +2x +2x +2x +2x +  +2x +2x +2x +2x +2x +2x +2x +2x +  +2x +2x +2x +2x +2x +2x +2x +2x +2x +2x +  +2x +2x +2x +2x +  +2x +2x +  +2x +2x +2x +  +2x +2x +2x +2x +  +  +2x +  +2x +2x +  +2x +2x +2x +2x +2x +  +2x +2x +  +2x +2x +2x +2x +  +2x +2x +2x +2x +2x +  +2x +2x +  +2x +2x + 
// TODO Organize this file by reducer type, to break this apart into
+// multiple files
+export const UPDATE_FILE_CONTENT = 'UPDATE_FILE_CONTENT';
+export const TOGGLE_SKETCH = 'TOGGLE_SKETCH';
+ 
+export const START_SKETCH = 'START_SKETCH';
+export const STOP_SKETCH = 'STOP_SKETCH';
+ 
+export const START_ACCESSIBLE_OUTPUT = 'START_ACCESSIBLE_OUTPUT';
+export const STOP_ACCESSIBLE_OUTPUT = 'STOP_ACCESSIBLE_OUTPUT';
+ 
+export const OPEN_PREFERENCES = 'OPEN_PREFERENCES';
+export const CLOSE_PREFERENCES = 'CLOSE_PREFERENCES';
+export const SET_FONT_SIZE = 'SET_FONT_SIZE';
+export const SET_LINE_NUMBERS = 'SET_LINE_NUMBERS';
+ 
+export const AUTH_USER = 'AUTH_USER';
+export const UNAUTH_USER = 'UNAUTH_USER';
+export const AUTH_ERROR = 'AUTH_ERROR';
+ 
+export const SETTINGS_UPDATED = 'SETTINGS_UPDATED';
+ 
+export const API_KEY_CREATED = 'API_KEY_CREATED';
+export const API_KEY_REMOVED = 'API_KEY_REMOVED';
+ 
+export const SET_PROJECT_NAME = 'SET_PROJECT_NAME';
+export const RENAME_PROJECT = 'RENAME_PROJECT';
+ 
+export const PROJECT_SAVE_SUCCESS = 'PROJECT_SAVE_SUCCESS';
+export const PROJECT_SAVE_FAIL = 'PROJECT_SAVE_FAIL';
+export const NEW_PROJECT = 'NEW_PROJECT';
+export const RESET_PROJECT = 'RESET_PROJECT';
+export const SHOW_EDIT_PROJECT_NAME = 'SHOW_EDIT_PROJECT_NAME';
+export const HIDE_EDIT_PROJECT_NAME = 'HIDE_EDIT_PROJECT_NAME';
+ 
+export const SET_PROJECT = 'SET_PROJECT';
+export const SET_PROJECTS = 'SET_PROJECTS';
+ 
+export const SET_COLLECTIONS = 'SET_COLLECTIONS';
+export const CREATE_COLLECTION = 'CREATED_COLLECTION';
+export const DELETE_COLLECTION = 'DELETE_COLLECTION';
+ 
+export const ADD_TO_COLLECTION = 'ADD_TO_COLLECTION';
+export const REMOVE_FROM_COLLECTION = 'REMOVE_FROM_COLLECTION';
+export const EDIT_COLLECTION = 'EDIT_COLLECTION';
+ 
+export const DELETE_PROJECT = 'DELETE_PROJECT';
+ 
+export const SET_SELECTED_FILE = 'SET_SELECTED_FILE';
+export const SHOW_MODAL = 'SHOW_MODAL';
+export const HIDE_MODAL = 'HIDE_MODAL';
+export const CREATE_FILE = 'CREATE_FILE';
+export const SET_BLOB_URL = 'SET_BLOB_URL';
+ 
+export const EXPAND_SIDEBAR = 'EXPAND_SIDEBAR';
+export const COLLAPSE_SIDEBAR = 'COLLAPSE_SIDEBAR';
+ 
+export const CONSOLE_EVENT = 'CONSOLE_EVENT';
+export const CLEAR_CONSOLE = 'CLEAR_CONSOLE';
+export const EXPAND_CONSOLE = 'EXPAND_CONSOLE';
+export const COLLAPSE_CONSOLE = 'COLLAPSE_CONSOLE';
+ 
+export const UPDATE_LINT_MESSAGE = 'UPDATE_LINT_MESSAGE';
+export const CLEAR_LINT_MESSAGE = 'CLEAR_LINT_MESSAGE';
+ 
+export const UPDATE_FILE_NAME = 'UPDATE_FILE_NAME';
+export const DELETE_FILE = 'DELETE_FILE';
+ 
+export const SET_AUTOSAVE = 'SET_AUTOSAVE';
+export const SET_LINEWRAP = 'SET_LINEWRAP';
+export const SET_LINT_WARNING = 'SET_LINT_WARNING';
+export const SET_PREFERENCES = 'SET_PREFERENCES';
+export const SET_TEXT_OUTPUT = 'SET_TEXT_OUTPUT';
+export const SET_GRID_OUTPUT = 'SET_GRID_OUTPUT';
+export const SET_SOUND_OUTPUT = 'SET_SOUND_OUTPUT';
+ 
+export const OPEN_PROJECT_OPTIONS = 'OPEN_PROJECT_OPTIONS';
+export const CLOSE_PROJECT_OPTIONS = 'CLOSE_PROJECT_OPTIONS';
+export const SHOW_NEW_FOLDER_MODAL = 'SHOW_NEW_FOLDER_MODAL';
+export const CLOSE_NEW_FOLDER_MODAL = 'CLOSE_NEW_FOLDER_MODAL';
+export const SHOW_FOLDER_CHILDREN = 'SHOW_FOLDER_CHILDREN';
+export const HIDE_FOLDER_CHILDREN = 'HIDE_FOLDER_CHILDREN';
+export const OPEN_UPLOAD_FILE_MODAL = 'OPEN_UPLOAD_FILE_MODAL';
+export const CLOSE_UPLOAD_FILE_MODAL = 'CLOSE_UPLOAD_FILE_MODAL';
+ 
+export const SHOW_SHARE_MODAL = 'SHOW_SHARE_MODAL';
+export const CLOSE_SHARE_MODAL = 'CLOSE_SHARE_MODAL';
+export const SHOW_EDITOR_OPTIONS = 'SHOW_EDITOR_OPTIONS';
+export const CLOSE_EDITOR_OPTIONS = 'CLOSE_EDITOR_OPTIONS';
+export const SHOW_KEYBOARD_SHORTCUT_MODAL = 'SHOW_KEYBOARD_SHORTCUT_MODAL';
+export const CLOSE_KEYBOARD_SHORTCUT_MODAL = 'CLOSE_KEYBOARD_SHORTCUT_MODAL';
+export const SHOW_TOAST = 'SHOW_TOAST';
+export const HIDE_TOAST = 'HIDE_TOAST';
+export const SET_TOAST_TEXT = 'SET_TOAST_TEXT';
+export const SET_THEME = 'SET_THEME';
+ 
+export const SET_UNSAVED_CHANGES = 'SET_UNSAVED_CHANGES';
+export const SET_AUTOREFRESH = 'SET_AUTOREFRESH';
+export const START_SKETCH_REFRESH = 'START_SKETCH_REFRESH';
+export const END_SKETCH_REFRESH = 'END_SKETCH_REFRESH';
+ 
+export const DETECT_INFINITE_LOOPS = 'DETECT_INFINITE_LOOPS';
+export const RESET_INFINITE_LOOPS = 'RESET_INFINITE_LOOPS';
+ 
+export const RESET_PASSWORD_INITIATE = 'RESET_PASSWORD_INITIATE';
+export const RESET_PASSWORD_RESET = 'RESET_PASSWORD_RESET';
+export const INVALID_RESET_PASSWORD_TOKEN = 'INVALID_RESET_PASSWORD_TOKEN';
+ 
+export const EMAIL_VERIFICATION_INITIATE = 'EMAIL_VERIFICATION_INITIATE';
+export const EMAIL_VERIFICATION_VERIFY = 'EMAIL_VERIFICATION_VERIFY';
+export const EMAIL_VERIFICATION_VERIFIED = 'EMAIL_VERIFICATION_VERIFIED';
+export const EMAIL_VERIFICATION_INVALID = 'EMAIL_VERIFICATION_INVALID';
+ 
+// eventually, handle errors more specifically and better
+export const ERROR = 'ERROR';
+ 
+export const JUST_OPENED_PROJECT = 'JUST_OPENED_PROJECT';
+export const RESET_JUST_OPENED_PROJECT = 'RESET_JUST_OPENED_PROJECT';
+ 
+export const SET_PROJECT_SAVED_TIME = 'SET_PROJECT_SAVED_TIME';
+export const RESET_PROJECT_SAVED_TIME = 'RESET_PROJECT_SAVED_TIME';
+export const SET_PREVIOUS_PATH = 'SET_PREVIOUS_PATH';
+export const SHOW_ERROR_MODAL = 'SHOW_ERROR_MODAL';
+export const HIDE_ERROR_MODAL = 'HIDE_ERROR_MODAL';
+ 
+export const PERSIST_STATE = 'PERSIST_STATE';
+export const CLEAR_PERSISTED_STATE = 'CLEAR_PERSISTED_STATE';
+ 
+export const HIDE_RUNTIME_ERROR_WARNING = 'HIDE_RUNTIME_ERROR_WARNING';
+export const SHOW_RUNTIME_ERROR_WARNING = 'SHOW_RUNTIME_ERROR_WARNING';
+export const SET_ASSETS = 'SET_ASSETS';
+export const DELETE_ASSET = 'DELETE_ASSET';
+ 
+export const TOGGLE_DIRECTION = 'TOGGLE_DIRECTION';
+export const SET_SORTING = 'SET_SORTING';
+export const SET_SORT_PARAMS = 'SET_SORT_PARAMS';
+export const SET_SEARCH_TERM = 'SET_SEARCH_TERM';
+export const CLOSE_SKETCHLIST_MODAL = 'CLOSE_SKETCHLIST_MODAL';
+ 
+export const START_LOADING = 'START_LOADING';
+export const STOP_LOADING = 'STOP_LOADING';
+ 
+export const START_SAVING_PROJECT = 'START_SAVING_PROJECT';
+export const END_SAVING_PROJECT = 'END_SAVING_PROJECT';
+ 
+ +
+
+ + + + + + + + + \ No newline at end of file diff --git a/coverage/lcov-report/client/index.html b/coverage/lcov-report/client/index.html new file mode 100644 index 00000000..c69b9e66 --- /dev/null +++ b/coverage/lcov-report/client/index.html @@ -0,0 +1,125 @@ + + + + + + Code coverage report for client + + + + + + + + +
+
+

All files client

+
+ +
+ 93.44% + Statements + 114/122 +
+ + +
+ 100% + Branches + 0/0 +
+ + +
+ 0% + Functions + 0/3 +
+ + +
+ 93.44% + Lines + 114/122 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+
+
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
FileStatementsBranchesFunctionsLines
constants.js +
+
100%109/109100%0/0100%0/0100%109/109
persistState.js +
+
38.46%5/13100%0/00%0/338.46%5/13
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/coverage/lcov-report/client/modules/IDE/actions/console.js.html b/coverage/lcov-report/client/modules/IDE/actions/console.js.html new file mode 100644 index 00000000..605373b9 --- /dev/null +++ b/coverage/lcov-report/client/modules/IDE/actions/console.js.html @@ -0,0 +1,121 @@ + + + + + + Code coverage report for client/modules/IDE/actions/console.js + + + + + + + + +
+
+

All files / client/modules/IDE/actions console.js

+
+ +
+ 0% + Statements + 0/2 +
+ + +
+ 100% + Branches + 0/0 +
+ + +
+ 0% + Functions + 0/2 +
+ + +
+ 0% + Lines + 0/2 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15  +  +  +  +  +  +  +  +  +  +  +  +  +  + 
import * as ActionTypes from '../../../constants';
+ 
+export function clearConsole() {
+  return {
+    type: ActionTypes.CLEAR_CONSOLE
+  };
+}
+ 
+export function dispatchConsoleEvent(messages) {
+  return {
+    type: ActionTypes.CONSOLE_EVENT,
+    event: messages
+  };
+}
+ 
+ +
+
+ + + + + + + + + \ No newline at end of file diff --git a/coverage/lcov-report/client/modules/IDE/actions/files.js.html b/coverage/lcov-report/client/modules/IDE/actions/files.js.html new file mode 100644 index 00000000..890f3a35 --- /dev/null +++ b/coverage/lcov-report/client/modules/IDE/actions/files.js.html @@ -0,0 +1,715 @@ + + + + + + Code coverage report for client/modules/IDE/actions/files.js + + + + + + + + +
+
+

All files / client/modules/IDE/actions files.js

+
+ +
+ 2.86% + Statements + 2/70 +
+ + +
+ 6.25% + Branches + 1/16 +
+ + +
+ 0% + Functions + 0/26 +
+ + +
+ 3.08% + Lines + 2/65 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30 +31 +32 +33 +34 +35 +36 +37 +38 +39 +40 +41 +42 +43 +44 +45 +46 +47 +48 +49 +50 +51 +52 +53 +54 +55 +56 +57 +58 +59 +60 +61 +62 +63 +64 +65 +66 +67 +68 +69 +70 +71 +72 +73 +74 +75 +76 +77 +78 +79 +80 +81 +82 +83 +84 +85 +86 +87 +88 +89 +90 +91 +92 +93 +94 +95 +96 +97 +98 +99 +100 +101 +102 +103 +104 +105 +106 +107 +108 +109 +110 +111 +112 +113 +114 +115 +116 +117 +118 +119 +120 +121 +122 +123 +124 +125 +126 +127 +128 +129 +130 +131 +132 +133 +134 +135 +136 +137 +138 +139 +140 +141 +142 +143 +144 +145 +146 +147 +148 +149 +150 +151 +152 +153 +154 +155 +156 +157 +158 +159 +160 +161 +162 +163 +164 +165 +166 +167 +168 +169 +170 +171 +172 +173 +174 +175 +176 +177 +178 +179 +180 +181 +182 +183 +184 +185 +186 +187 +188 +189 +190 +191 +192 +193 +194 +195 +196 +197 +198 +199 +200 +201 +202 +203 +204 +205 +206 +207 +208 +209 +210 +211 +212 +213  +  +  +  +  +  +  +  +1x +1x +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  + 
import axios from 'axios';
+import objectID from 'bson-objectid';
+import blobUtil from 'blob-util';
+import { reset } from 'redux-form';
+import * as ActionTypes from '../../../constants';
+import { setUnsavedChanges, closeNewFolderModal, closeNewFileModal } from './ide';
+import { setProjectSavedTime } from './project';
+ 
+const __process = (typeof global !== 'undefined' ? global : window).process;
+const ROOT_URL = __process.env.API_URL;
+ 
+function appendToFilename(filename, string) {
+  const dotIndex = filename.lastIndexOf('.');
+  if (dotIndex === -1) return filename + string;
+  return filename.substring(0, dotIndex) + string + filename.substring(dotIndex);
+}
+ 
+function createUniqueName(name, parentId, files) {
+  const siblingFiles = files.find(file => file.id === parentId)
+    .children.map(childFileId => files.find(file => file.id === childFileId));
+  let testName = name;
+  let index = 1;
+  let existingName = siblingFiles.find(file => name === file.name);
+ 
+  while (existingName) {
+    testName = appendToFilename(name, `-${index}`);
+    index += 1;
+    existingName = siblingFiles.find((file) => testName === file.name); // eslint-disable-line
+  }
+  return testName;
+}
+ 
+export function updateFileContent(id, content) {
+  return {
+    type: ActionTypes.UPDATE_FILE_CONTENT,
+    id,
+    content
+  };
+}
+ 
+export function createFile(formProps) {
+  return (dispatch, getState) => {
+    const state = getState();
+    const { parentId } = state.ide;
+    if (state.project.id) {
+      const postParams = {
+        name: createUniqueName(formProps.name, parentId, state.files),
+        url: formProps.url,
+        content: formProps.content || '',
+        parentId,
+        children: []
+      };
+      axios.post(`${ROOT_URL}/projects/${state.project.id}/files`, postParams, { withCredentials: true })
+        .then((response) => {
+          dispatch({
+            type: ActionTypes.CREATE_FILE,
+            ...response.data.updatedFile,
+            parentId
+          });
+          dispatch(setProjectSavedTime(response.data.project.updatedAt));
+          dispatch(closeNewFileModal());
+          dispatch(reset('new-file'));
+          // dispatch({
+          //   type: ActionTypes.HIDE_MODAL
+          // });
+          dispatch(setUnsavedChanges(true));
+        })
+        .catch(response => dispatch({
+          type: ActionTypes.ERROR,
+          error: response.data
+        }));
+    } else {
+      const id = objectID().toHexString();
+      dispatch({
+        type: ActionTypes.CREATE_FILE,
+        name: createUniqueName(formProps.name, parentId, state.files),
+        id,
+        _id: id,
+        url: formProps.url,
+        content: formProps.content || '',
+        parentId,
+        children: []
+      });
+      dispatch(reset('new-file'));
+      // dispatch({
+      //   type: ActionTypes.HIDE_MODAL
+      // });
+      dispatch(setUnsavedChanges(true));
+      dispatch(closeNewFileModal());
+    }
+  };
+}
+ 
+export function createFolder(formProps) {
+  return (dispatch, getState) => {
+    const state = getState();
+    const { parentId } = state.ide;
+    if (state.project.id) {
+      const postParams = {
+        name: createUniqueName(formProps.name, parentId, state.files),
+        content: '',
+        children: [],
+        parentId,
+        fileType: 'folder'
+      };
+      axios.post(`${ROOT_URL}/projects/${state.project.id}/files`, postParams, { withCredentials: true })
+        .then((response) => {
+          dispatch({
+            type: ActionTypes.CREATE_FILE,
+            ...response.data.updatedFile,
+            parentId
+          });
+          dispatch(setProjectSavedTime(response.data.project.updatedAt));
+          dispatch(closeNewFolderModal());
+        })
+        .catch(response => dispatch({
+          type: ActionTypes.ERROR,
+          error: response.data
+        }));
+    } else {
+      const id = objectID().toHexString();
+      dispatch({
+        type: ActionTypes.CREATE_FILE,
+        name: createUniqueName(formProps.name, parentId, state.files),
+        id,
+        _id: id,
+        content: '',
+        // TODO pass parent id from File Tree
+        parentId,
+        fileType: 'folder',
+        children: []
+      });
+      dispatch(closeNewFolderModal());
+    }
+  };
+}
+ 
+export function updateFileName(id, name) {
+  return (dispatch) => {
+    dispatch(setUnsavedChanges(true));
+    dispatch({
+      type: ActionTypes.UPDATE_FILE_NAME,
+      id,
+      name
+    });
+  };
+}
+ 
+export function deleteFile(id, parentId) {
+  return (dispatch, getState) => {
+    const state = getState();
+    if (state.project.id) {
+      const deleteConfig = {
+        params: {
+          parentId
+        }
+      };
+      axios.delete(`${ROOT_URL}/projects/${state.project.id}/files/${id}`, deleteConfig, { withCredentials: true })
+        .then(() => {
+          dispatch({
+            type: ActionTypes.DELETE_FILE,
+            id,
+            parentId
+          });
+        })
+        .catch((response) => {
+          dispatch({
+            type: ActionTypes.ERROR,
+            error: response.data
+          });
+        });
+    } else {
+      dispatch({
+        type: ActionTypes.DELETE_FILE,
+        id,
+        parentId
+      });
+    }
+  };
+}
+ 
+export function showFolderChildren(id) {
+  return {
+    type: ActionTypes.SHOW_FOLDER_CHILDREN,
+    id
+  };
+}
+ 
+export function hideFolderChildren(id) {
+  return {
+    type: ActionTypes.HIDE_FOLDER_CHILDREN,
+    id
+  };
+}
+ 
+export function setBlobUrl(file, blobURL) {
+  return {
+    type: ActionTypes.SET_BLOB_URL,
+    id: file.id,
+    blobURL
+  };
+}
+ 
+export function getBlobUrl(file) {
+  if (file.blobUrl) {
+    blobUtil.revokeObjectURL(file.blobUrl);
+  }
+ 
+  const fileBlob = blobUtil.createBlob([file.content], { type: 'text/plain' });
+  const blobURL = blobUtil.createObjectURL(fileBlob);
+  return blobURL;
+}
+ 
+ +
+
+ + + + + + + + + \ No newline at end of file diff --git a/coverage/lcov-report/client/modules/IDE/actions/ide.js.html b/coverage/lcov-report/client/modules/IDE/actions/ide.js.html new file mode 100644 index 00000000..f400470a --- /dev/null +++ b/coverage/lcov-report/client/modules/IDE/actions/ide.js.html @@ -0,0 +1,919 @@ + + + + + + Code coverage report for client/modules/IDE/actions/ide.js + + + + + + + + +
+
+

All files / client/modules/IDE/actions ide.js

+
+ +
+ 0% + Statements + 0/57 +
+ + +
+ 0% + Branches + 0/8 +
+ + +
+ 0% + Functions + 0/49 +
+ + +
+ 0% + Lines + 0/56 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30 +31 +32 +33 +34 +35 +36 +37 +38 +39 +40 +41 +42 +43 +44 +45 +46 +47 +48 +49 +50 +51 +52 +53 +54 +55 +56 +57 +58 +59 +60 +61 +62 +63 +64 +65 +66 +67 +68 +69 +70 +71 +72 +73 +74 +75 +76 +77 +78 +79 +80 +81 +82 +83 +84 +85 +86 +87 +88 +89 +90 +91 +92 +93 +94 +95 +96 +97 +98 +99 +100 +101 +102 +103 +104 +105 +106 +107 +108 +109 +110 +111 +112 +113 +114 +115 +116 +117 +118 +119 +120 +121 +122 +123 +124 +125 +126 +127 +128 +129 +130 +131 +132 +133 +134 +135 +136 +137 +138 +139 +140 +141 +142 +143 +144 +145 +146 +147 +148 +149 +150 +151 +152 +153 +154 +155 +156 +157 +158 +159 +160 +161 +162 +163 +164 +165 +166 +167 +168 +169 +170 +171 +172 +173 +174 +175 +176 +177 +178 +179 +180 +181 +182 +183 +184 +185 +186 +187 +188 +189 +190 +191 +192 +193 +194 +195 +196 +197 +198 +199 +200 +201 +202 +203 +204 +205 +206 +207 +208 +209 +210 +211 +212 +213 +214 +215 +216 +217 +218 +219 +220 +221 +222 +223 +224 +225 +226 +227 +228 +229 +230 +231 +232 +233 +234 +235 +236 +237 +238 +239 +240 +241 +242 +243 +244 +245 +246 +247 +248 +249 +250 +251 +252 +253 +254 +255 +256 +257 +258 +259 +260 +261 +262 +263 +264 +265 +266 +267 +268 +269 +270 +271 +272 +273 +274 +275 +276 +277 +278 +279 +280 +281  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  + 
import * as ActionTypes from '../../../constants';
+import { clearConsole } from './console';
+ 
+export function startVisualSketch() {
+  return {
+    type: ActionTypes.START_SKETCH
+  };
+}
+ 
+export function stopVisualSketch() {
+  return {
+    type: ActionTypes.STOP_SKETCH
+  };
+}
+ 
+export function startRefreshSketch() {
+  return {
+    type: ActionTypes.START_SKETCH_REFRESH
+  };
+}
+ 
+export function startSketchAndRefresh() {
+  return (dispatch) => {
+    dispatch(startVisualSketch());
+    dispatch(startRefreshSketch());
+  };
+}
+ 
+export function endSketchRefresh() {
+  return {
+    type: ActionTypes.END_SKETCH_REFRESH
+  };
+}
+ 
+export function startAccessibleOutput() {
+  return {
+    type: ActionTypes.START_ACCESSIBLE_OUTPUT
+  };
+}
+ 
+export function stopAccessibleOutput() {
+  return {
+    type: ActionTypes.STOP_ACCESSIBLE_OUTPUT
+  };
+}
+ 
+export function setSelectedFile(fileId) {
+  return {
+    type: ActionTypes.SET_SELECTED_FILE,
+    selectedFile: fileId
+  };
+}
+ 
+export function resetSelectedFile(previousId) {
+  return (dispatch, getState) => {
+    const state = getState();
+    const newId = state.files.find(file => file.name !== 'root' && file.id !== previousId).id;
+    dispatch({
+      type: ActionTypes.SET_SELECTED_FILE,
+      selectedFile: newId
+    });
+  };
+}
+ 
+export function newFile(parentId) {
+  return {
+    type: ActionTypes.SHOW_MODAL,
+    parentId
+  };
+}
+ 
+export function closeNewFileModal() {
+  return {
+    type: ActionTypes.HIDE_MODAL
+  };
+}
+ 
+export function openUploadFileModal(parentId) {
+  return {
+    type: ActionTypes.OPEN_UPLOAD_FILE_MODAL,
+    parentId
+  };
+}
+ 
+export function closeUploadFileModal() {
+  return {
+    type: ActionTypes.CLOSE_UPLOAD_FILE_MODAL
+  };
+}
+ 
+export function expandSidebar() {
+  return {
+    type: ActionTypes.EXPAND_SIDEBAR
+  };
+}
+ 
+export function collapseSidebar() {
+  return {
+    type: ActionTypes.COLLAPSE_SIDEBAR
+  };
+}
+ 
+export function expandConsole() {
+  return {
+    type: ActionTypes.EXPAND_CONSOLE
+  };
+}
+ 
+export function collapseConsole() {
+  return {
+    type: ActionTypes.COLLAPSE_CONSOLE
+  };
+}
+ 
+export function openPreferences() {
+  return {
+    type: ActionTypes.OPEN_PREFERENCES
+  };
+}
+ 
+export function closePreferences() {
+  return {
+    type: ActionTypes.CLOSE_PREFERENCES
+  };
+}
+ 
+export function openProjectOptions() {
+  return {
+    type: ActionTypes.OPEN_PROJECT_OPTIONS
+  };
+}
+ 
+export function closeProjectOptions() {
+  return {
+    type: ActionTypes.CLOSE_PROJECT_OPTIONS
+  };
+}
+ 
+export function newFolder(parentId) {
+  return {
+    type: ActionTypes.SHOW_NEW_FOLDER_MODAL,
+    parentId
+  };
+}
+ 
+export function closeNewFolderModal() {
+  return {
+    type: ActionTypes.CLOSE_NEW_FOLDER_MODAL
+  };
+}
+ 
+export function showShareModal(projectId, projectName, ownerUsername) {
+  return (dispatch, getState) => {
+    const { project, user } = getState();
+    dispatch({
+      type: ActionTypes.SHOW_SHARE_MODAL,
+      payload: {
+        shareModalProjectId: projectId || project.id,
+        shareModalProjectName: projectName || project.name,
+        shareModalProjectUsername: ownerUsername || user.username
+      }
+    });
+  };
+}
+ 
+export function closeShareModal() {
+  return {
+    type: ActionTypes.CLOSE_SHARE_MODAL
+  };
+}
+ 
+export function showEditorOptions() {
+  return {
+    type: ActionTypes.SHOW_EDITOR_OPTIONS
+  };
+}
+ 
+export function closeEditorOptions() {
+  return {
+    type: ActionTypes.CLOSE_EDITOR_OPTIONS
+  };
+}
+ 
+export function showKeyboardShortcutModal() {
+  return {
+    type: ActionTypes.SHOW_KEYBOARD_SHORTCUT_MODAL
+  };
+}
+ 
+export function closeKeyboardShortcutModal() {
+  return {
+    type: ActionTypes.CLOSE_KEYBOARD_SHORTCUT_MODAL
+  };
+}
+ 
+export function setUnsavedChanges(value) {
+  return {
+    type: ActionTypes.SET_UNSAVED_CHANGES,
+    value
+  };
+}
+ 
+export function detectInfiniteLoops(message) {
+  return {
+    type: ActionTypes.DETECT_INFINITE_LOOPS,
+    message
+  };
+}
+ 
+export function resetInfiniteLoops() {
+  return {
+    type: ActionTypes.RESET_INFINITE_LOOPS
+  };
+}
+ 
+export function justOpenedProject() {
+  return {
+    type: ActionTypes.JUST_OPENED_PROJECT,
+  };
+}
+ 
+export function resetJustOpenedProject() {
+  return {
+    type: ActionTypes.RESET_JUST_OPENED_PROJECT
+  };
+}
+ 
+export function setPreviousPath(path) {
+  return {
+    type: ActionTypes.SET_PREVIOUS_PATH,
+    path
+  };
+}
+ 
+export function showErrorModal(modalType) {
+  return {
+    type: ActionTypes.SHOW_ERROR_MODAL,
+    modalType
+  };
+}
+ 
+export function hideErrorModal() {
+  return {
+    type: ActionTypes.HIDE_ERROR_MODAL
+  };
+}
+ 
+export function hideRuntimeErrorWarning() {
+  return {
+    type: ActionTypes.HIDE_RUNTIME_ERROR_WARNING
+  };
+}
+ 
+export function showRuntimeErrorWarning() {
+  return {
+    type: ActionTypes.SHOW_RUNTIME_ERROR_WARNING
+  };
+}
+ 
+export function startSketch() {
+  return (dispatch) => {
+    dispatch(clearConsole());
+    dispatch(startSketchAndRefresh());
+  };
+}
+ 
+export function startAccessibleSketch() {
+  return (dispatch) => {
+    dispatch(clearConsole());
+    dispatch(startAccessibleOutput());
+    dispatch(startSketchAndRefresh());
+  };
+}
+ 
+export function stopSketch() {
+  return (dispatch) => {
+    dispatch(stopAccessibleOutput());
+    dispatch(stopVisualSketch());
+  };
+}
+ 
+ +
+
+ + + + + + + + + \ No newline at end of file diff --git a/coverage/lcov-report/client/modules/IDE/actions/index.html b/coverage/lcov-report/client/modules/IDE/actions/index.html new file mode 100644 index 00000000..e4b85fd1 --- /dev/null +++ b/coverage/lcov-report/client/modules/IDE/actions/index.html @@ -0,0 +1,185 @@ + + + + + + Code coverage report for client/modules/IDE/actions + + + + + + + + +
+
+

All files client/modules/IDE/actions

+
+ +
+ 1.63% + Statements + 6/368 +
+ + +
+ 3.03% + Branches + 3/99 +
+ + +
+ 0% + Functions + 0/167 +
+ + +
+ 1.69% + Lines + 6/354 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+
+
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
FileStatementsBranchesFunctionsLines
console.js +
+
0%0/2100%0/00%0/20%0/2
files.js +
+
2.86%2/706.25%1/160%0/263.08%2/65
ide.js +
+
0%0/570%0/80%0/490%0/56
preferences.js +
+
2.94%2/684.55%1/220%0/252.94%2/68
project.js +
+
1.21%2/1651.89%1/530%0/601.27%2/158
toast.js +
+
0%0/6100%0/00%0/50%0/5
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/coverage/lcov-report/client/modules/IDE/actions/preferences.js.html b/coverage/lcov-report/client/modules/IDE/actions/preferences.js.html new file mode 100644 index 00000000..f7c8d85c --- /dev/null +++ b/coverage/lcov-report/client/modules/IDE/actions/preferences.js.html @@ -0,0 +1,715 @@ + + + + + + Code coverage report for client/modules/IDE/actions/preferences.js + + + + + + + + +
+
+

All files / client/modules/IDE/actions preferences.js

+
+ +
+ 2.94% + Statements + 2/68 +
+ + +
+ 4.55% + Branches + 1/22 +
+ + +
+ 0% + Functions + 0/25 +
+ + +
+ 2.94% + Lines + 2/68 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30 +31 +32 +33 +34 +35 +36 +37 +38 +39 +40 +41 +42 +43 +44 +45 +46 +47 +48 +49 +50 +51 +52 +53 +54 +55 +56 +57 +58 +59 +60 +61 +62 +63 +64 +65 +66 +67 +68 +69 +70 +71 +72 +73 +74 +75 +76 +77 +78 +79 +80 +81 +82 +83 +84 +85 +86 +87 +88 +89 +90 +91 +92 +93 +94 +95 +96 +97 +98 +99 +100 +101 +102 +103 +104 +105 +106 +107 +108 +109 +110 +111 +112 +113 +114 +115 +116 +117 +118 +119 +120 +121 +122 +123 +124 +125 +126 +127 +128 +129 +130 +131 +132 +133 +134 +135 +136 +137 +138 +139 +140 +141 +142 +143 +144 +145 +146 +147 +148 +149 +150 +151 +152 +153 +154 +155 +156 +157 +158 +159 +160 +161 +162 +163 +164 +165 +166 +167 +168 +169 +170 +171 +172 +173 +174 +175 +176 +177 +178 +179 +180 +181 +182 +183 +184 +185 +186 +187 +188 +189 +190 +191 +192 +193 +194 +195 +196 +197 +198 +199 +200 +201 +202 +203 +204 +205 +206 +207 +208 +209 +210 +211 +212 +213  +  +  +1x +1x +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  + 
import axios from 'axios';
+import * as ActionTypes from '../../../constants';
+ 
+const __process = (typeof global !== 'undefined' ? global : window).process;
+const ROOT_URL = __process.env.API_URL;
+ 
+function updatePreferences(formParams, dispatch) {
+  axios.put(`${ROOT_URL}/preferences`, formParams, { withCredentials: true })
+    .then(() => {
+    })
+    .catch(response => dispatch({
+      type: ActionTypes.ERROR,
+      error: response.data
+    }));
+}
+ 
+export function setFontSize(value) {
+  return (dispatch, getState) => { // eslint-disable-line
+    dispatch({
+      type: ActionTypes.SET_FONT_SIZE,
+      value
+    });
+    const state = getState();
+    if (state.user.authenticated) {
+      const formParams = {
+        preferences: {
+          fontSize: value
+        }
+      };
+      updatePreferences(formParams, dispatch);
+    }
+  };
+}
+ 
+export function setLineNumbers(value) {
+  return (dispatch, getState) => {
+    dispatch({
+      type: ActionTypes.SET_LINE_NUMBERS,
+      value
+    });
+    const state = getState();
+    if (state.user.authenticated) {
+      const formParams = {
+        preferences: {
+          lineNumbers: value
+        }
+      };
+      updatePreferences(formParams, dispatch);
+    }
+  };
+}
+ 
+export function setAutosave(value) {
+  return (dispatch, getState) => {
+    dispatch({
+      type: ActionTypes.SET_AUTOSAVE,
+      value
+    });
+    const state = getState();
+    if (state.user.authenticated) {
+      const formParams = {
+        preferences: {
+          autosave: value
+        }
+      };
+      updatePreferences(formParams, dispatch);
+    }
+  };
+}
+ 
+export function setLinewrap(value) {
+  return (dispatch, getState) => {
+    dispatch({
+      type: ActionTypes.SET_LINEWRAP,
+      value
+    });
+    const state = getState();
+    if (state.user.authenticated) {
+      const formParams = {
+        preferences: {
+          linewrap: value
+        }
+      };
+      updatePreferences(formParams, dispatch);
+    }
+  };
+}
+ 
+export function setLintWarning(value) {
+  return (dispatch, getState) => {
+    dispatch({
+      type: ActionTypes.SET_LINT_WARNING,
+      value
+    });
+    const state = getState();
+    if (state.user.authenticated) {
+      const formParams = {
+        preferences: {
+          lintWarning: value
+        }
+      };
+      updatePreferences(formParams, dispatch);
+    }
+  };
+}
+ 
+export function setTextOutput(value) {
+  return (dispatch, getState) => {
+    dispatch({
+      type: ActionTypes.SET_TEXT_OUTPUT,
+      value
+    });
+    const state = getState();
+    if (state.user.authenticated) {
+      const formParams = {
+        preferences: {
+          textOutput: value
+        }
+      };
+      updatePreferences(formParams, dispatch);
+    }
+  };
+}
+ 
+export function setGridOutput(value) {
+  return (dispatch, getState) => {
+    dispatch({
+      type: ActionTypes.SET_GRID_OUTPUT,
+      value
+    });
+    const state = getState();
+    if (state.user.authenticated) {
+      const formParams = {
+        preferences: {
+          gridOutput: value
+        }
+      };
+      updatePreferences(formParams, dispatch);
+    }
+  };
+}
+ 
+export function setSoundOutput(value) {
+  return (dispatch, getState) => {
+    dispatch({
+      type: ActionTypes.SET_SOUND_OUTPUT,
+      value
+    });
+    const state = getState();
+    if (state.user.authenticated) {
+      const formParams = {
+        preferences: {
+          soundOutput: value
+        }
+      };
+      updatePreferences(formParams, dispatch);
+    }
+  };
+}
+ 
+export function setTheme(value) {
+  // return {
+  //   type: ActionTypes.SET_THEME,
+  //   value
+  // };
+  return (dispatch, getState) => {
+    dispatch({
+      type: ActionTypes.SET_THEME,
+      value
+    });
+    const state = getState();
+    if (state.user.authenticated) {
+      const formParams = {
+        preferences: {
+          theme: value
+        }
+      };
+      updatePreferences(formParams, dispatch);
+    }
+  };
+}
+ 
+export function setAutorefresh(value) {
+  // return {
+  //   type: ActionTypes.SET_AUTOREFRESH,
+  //   value
+  // };
+  return (dispatch, getState) => {
+    dispatch({
+      type: ActionTypes.SET_AUTOREFRESH,
+      value
+    });
+    const state = getState();
+    if (state.user.authenticated) {
+      const formParams = {
+        preferences: {
+          autorefresh: value
+        }
+      };
+      updatePreferences(formParams, dispatch);
+    }
+  };
+}
+ 
+export function setAllAccessibleOutput(value) {
+  return (dispatch) => {
+    dispatch(setTextOutput(value));
+    dispatch(setGridOutput(value));
+    dispatch(setSoundOutput(value));
+  };
+}
+ 
+ 
+ +
+
+ + + + + + + + + \ No newline at end of file diff --git a/coverage/lcov-report/client/modules/IDE/actions/project.js.html b/coverage/lcov-report/client/modules/IDE/actions/project.js.html new file mode 100644 index 00000000..ceab3c64 --- /dev/null +++ b/coverage/lcov-report/client/modules/IDE/actions/project.js.html @@ -0,0 +1,1225 @@ + + + + + + Code coverage report for client/modules/IDE/actions/project.js + + + + + + + + +
+
+

All files / client/modules/IDE/actions project.js

+
+ +
+ 1.21% + Statements + 2/165 +
+ + +
+ 1.89% + Branches + 1/53 +
+ + +
+ 0% + Functions + 0/60 +
+ + +
+ 1.27% + Lines + 2/158 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30 +31 +32 +33 +34 +35 +36 +37 +38 +39 +40 +41 +42 +43 +44 +45 +46 +47 +48 +49 +50 +51 +52 +53 +54 +55 +56 +57 +58 +59 +60 +61 +62 +63 +64 +65 +66 +67 +68 +69 +70 +71 +72 +73 +74 +75 +76 +77 +78 +79 +80 +81 +82 +83 +84 +85 +86 +87 +88 +89 +90 +91 +92 +93 +94 +95 +96 +97 +98 +99 +100 +101 +102 +103 +104 +105 +106 +107 +108 +109 +110 +111 +112 +113 +114 +115 +116 +117 +118 +119 +120 +121 +122 +123 +124 +125 +126 +127 +128 +129 +130 +131 +132 +133 +134 +135 +136 +137 +138 +139 +140 +141 +142 +143 +144 +145 +146 +147 +148 +149 +150 +151 +152 +153 +154 +155 +156 +157 +158 +159 +160 +161 +162 +163 +164 +165 +166 +167 +168 +169 +170 +171 +172 +173 +174 +175 +176 +177 +178 +179 +180 +181 +182 +183 +184 +185 +186 +187 +188 +189 +190 +191 +192 +193 +194 +195 +196 +197 +198 +199 +200 +201 +202 +203 +204 +205 +206 +207 +208 +209 +210 +211 +212 +213 +214 +215 +216 +217 +218 +219 +220 +221 +222 +223 +224 +225 +226 +227 +228 +229 +230 +231 +232 +233 +234 +235 +236 +237 +238 +239 +240 +241 +242 +243 +244 +245 +246 +247 +248 +249 +250 +251 +252 +253 +254 +255 +256 +257 +258 +259 +260 +261 +262 +263 +264 +265 +266 +267 +268 +269 +270 +271 +272 +273 +274 +275 +276 +277 +278 +279 +280 +281 +282 +283 +284 +285 +286 +287 +288 +289 +290 +291 +292 +293 +294 +295 +296 +297 +298 +299 +300 +301 +302 +303 +304 +305 +306 +307 +308 +309 +310 +311 +312 +313 +314 +315 +316 +317 +318 +319 +320 +321 +322 +323 +324 +325 +326 +327 +328 +329 +330 +331 +332 +333 +334 +335 +336 +337 +338 +339 +340 +341 +342 +343 +344 +345 +346 +347 +348 +349 +350 +351 +352 +353 +354 +355 +356 +357 +358 +359 +360 +361 +362 +363 +364 +365 +366 +367 +368 +369 +370 +371 +372 +373 +374 +375 +376 +377 +378 +379 +380 +381 +382 +383  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +2x +2x +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  + 
import { browserHistory } from 'react-router';
+import axios from 'axios';
+import objectID from 'bson-objectid';
+import each from 'async/each';
+import isEqual from 'lodash/isEqual';
+import * as ActionTypes from '../../../constants';
+import { showToast, setToastText } from './toast';
+import {
+  setUnsavedChanges,
+  justOpenedProject,
+  resetJustOpenedProject,
+  showErrorModal,
+  setPreviousPath
+} from './ide';
+import { clearState, saveState } from '../../../persistState';
+ 
+const __process = (typeof global !== 'undefined' ? global : window).process;
+const ROOT_URL = __process.env.API_URL;
+ 
+export function setProject(project) {
+  return {
+    type: ActionTypes.SET_PROJECT,
+    project,
+    files: project.files,
+    owner: project.user
+  };
+}
+ 
+export function setProjectName(name) {
+  return {
+    type: ActionTypes.SET_PROJECT_NAME,
+    name
+  };
+}
+ 
+export function projectSaveFail(error) {
+  return {
+    type: ActionTypes.PROJECT_SAVE_FAIL,
+    error
+  };
+}
+ 
+export function setNewProject(project) {
+  return {
+    type: ActionTypes.NEW_PROJECT,
+    project,
+    owner: project.user,
+    files: project.files
+  };
+}
+ 
+export function getProject(id) {
+  return (dispatch, getState) => {
+    dispatch(justOpenedProject());
+    axios.get(`${ROOT_URL}/projects/${id}`, { withCredentials: true })
+      .then((response) => {
+        dispatch(setProject(response.data));
+        dispatch(setUnsavedChanges(false));
+      })
+      .catch(response => dispatch({
+        type: ActionTypes.ERROR,
+        error: response.data
+      }));
+  };
+}
+ 
+export function persistState() {
+  return (dispatch, getState) => {
+    dispatch({
+      type: ActionTypes.PERSIST_STATE,
+    });
+    const state = getState();
+    saveState(state);
+  };
+}
+ 
+export function clearPersistedState() {
+  return (dispatch) => {
+    dispatch({
+      type: ActionTypes.CLEAR_PERSISTED_STATE,
+    });
+    clearState();
+  };
+}
+ 
+export function startSavingProject() {
+  return {
+    type: ActionTypes.START_SAVING_PROJECT
+  };
+}
+ 
+export function endSavingProject() {
+  return {
+    type: ActionTypes.END_SAVING_PROJECT
+  };
+}
+ 
+export function projectSaveSuccess() {
+  return {
+    type: ActionTypes.PROJECT_SAVE_SUCCESS
+  };
+}
+ 
+// want a function that will check for changes on the front end
+function getSynchedProject(currentState, responseProject) {
+  let hasChanges = false;
+  const synchedProject = Object.assign({}, responseProject);
+  const currentFiles = currentState.files.map(({ name, children, content }) => ({ name, children, content }));
+  const responseFiles = responseProject.files.map(({ name, children, content }) => ({ name, children, content }));
+  if (!isEqual(currentFiles, responseFiles)) {
+    synchedProject.files = currentState.files;
+    hasChanges = true;
+  }
+  if (currentState.project.name !== responseProject.name) {
+    synchedProject.name = currentState.project.name;
+    hasChanges = true;
+  }
+  return {
+    synchedProject,
+    hasChanges
+  };
+}
+ 
+export function saveProject(selectedFile = null, autosave = false) {
+  return (dispatch, getState) => {
+    const state = getState();
+    if (state.project.isSaving) {
+      return Promise.resolve();
+    }
+    dispatch(startSavingProject());
+    if (state.user.id && state.project.owner && state.project.owner.id !== state.user.id) {
+      return Promise.reject();
+    }
+    const formParams = Object.assign({}, state.project);
+    formParams.files = [...state.files];
+ 
+    if (selectedFile) {
+      const fileToUpdate = formParams.files.find(file => file.id === selectedFile.id);
+      fileToUpdate.content = selectedFile.content;
+    }
+    if (state.project.id) {
+      return axios.put(`${ROOT_URL}/projects/${state.project.id}`, formParams, { withCredentials: true })
+        .then((response) => {
+          dispatch(endSavingProject());
+          dispatch(setUnsavedChanges(false));
+          const { hasChanges, synchedProject } = getSynchedProject(getState(), response.data);
+          if (hasChanges) {
+            dispatch(setUnsavedChanges(true));
+          }
+          dispatch(setProject(synchedProject));
+          dispatch(projectSaveSuccess());
+          if (!autosave) {
+            if (state.ide.justOpenedProject && state.preferences.autosave) {
+              dispatch(showToast(5500));
+              dispatch(setToastText('Project saved.'));
+              setTimeout(() => dispatch(setToastText('Autosave enabled.')), 1500);
+              dispatch(resetJustOpenedProject());
+            } else {
+              dispatch(showToast(1500));
+              dispatch(setToastText('Project saved.'));
+            }
+          }
+        })
+        .catch((response) => {
+          dispatch(endSavingProject());
+          if (response.status === 403) {
+            dispatch(showErrorModal('staleSession'));
+          } else if (response.status === 409) {
+            dispatch(showErrorModal('staleProject'));
+          } else {
+            dispatch(projectSaveFail(response.data));
+          }
+        });
+    }
+ 
+    return axios.post(`${ROOT_URL}/projects`, formParams, { withCredentials: true })
+      .then((response) => {
+        dispatch(endSavingProject());
+        const { hasChanges, synchedProject } = getSynchedProject(getState(), response.data);
+        if (hasChanges) {
+          dispatch(setNewProject(synchedProject));
+          dispatch(setUnsavedChanges(false));
+          browserHistory.push(`/${response.data.user.username}/sketches/${response.data.id}`);
+          dispatch(setUnsavedChanges(true));
+        } else {
+          dispatch(setNewProject(synchedProject));
+          dispatch(setUnsavedChanges(false));
+          browserHistory.push(`/${response.data.user.username}/sketches/${response.data.id}`);
+        }
+        dispatch(projectSaveSuccess());
+        if (!autosave) {
+          if (state.preferences.autosave) {
+            dispatch(showToast(5500));
+            dispatch(setToastText('Project saved.'));
+            setTimeout(() => dispatch(setToastText('Autosave enabled.')), 1500);
+            dispatch(resetJustOpenedProject());
+          } else {
+            dispatch(showToast(1500));
+            dispatch(setToastText('Project saved.'));
+          }
+        }
+      })
+      .catch((response) => {
+        dispatch(endSavingProject());
+        if (response.status === 403) {
+          dispatch(showErrorModal('staleSession'));
+        } else {
+          dispatch(projectSaveFail(response.data));
+        }
+      });
+  };
+}
+ 
+export function autosaveProject() {
+  return (dispatch, getState) => {
+    saveProject(null, true)(dispatch, getState);
+  };
+}
+ 
+export function exportProjectAsZip(projectId) {
+  const win = window.open(`${ROOT_URL}/projects/${projectId}/zip`, '_blank');
+  win.focus();
+}
+ 
+export function resetProject() {
+  return {
+    type: ActionTypes.RESET_PROJECT
+  };
+}
+ 
+export function newProject() {
+  setTimeout(() => {
+    browserHistory.push('/');
+  }, 0);
+  return resetProject();
+}
+ 
+function generateNewIdsForChildren(file, files) {
+  const newChildren = [];
+  file.children.forEach((childId) => {
+    const child = files.find(childFile => childFile.id === childId);
+    const newId = objectID().toHexString();
+    child.id = newId;
+    child._id = newId;
+    newChildren.push(newId);
+    generateNewIdsForChildren(child, files);
+  });
+  file.children = newChildren; // eslint-disable-line
+}
+ 
+export function cloneProject(id) {
+  return (dispatch, getState) => {
+    dispatch(setUnsavedChanges(false));
+    new Promise((resolve, reject) => {
+      if (!id) {
+        resolve(getState());
+      } else {
+        fetch(`${ROOT_URL}/projects/${id}`)
+          .then(res => res.json())
+          .then(data => resolve({
+            files: data.files,
+            project: {
+              name: data.name
+            }
+          }));
+      }
+    }).then((state) => {
+      const newFiles = state.files.map((file) => { // eslint-disable-line
+        return { ...file };
+      });
+ 
+      // generate new IDS for all files
+      const rootFile = newFiles.find(file => file.name === 'root');
+      const newRootFileId = objectID().toHexString();
+      rootFile.id = newRootFileId;
+      rootFile._id = newRootFileId;
+      generateNewIdsForChildren(rootFile, newFiles);
+ 
+      // duplicate all files hosted on S3
+      each(newFiles, (file, callback) => {
+        if (file.url && file.url.includes('amazonaws')) {
+          const formParams = {
+            url: file.url
+          };
+          axios.post(`${ROOT_URL}/S3/copy`, formParams, { withCredentials: true })
+            .then((response) => {
+              file.url = response.data.url;
+              callback(null);
+            });
+        } else {
+          callback(null);
+        }
+      }, (err) => {
+        // if not errors in duplicating the files on S3, then duplicate it
+        const formParams = Object.assign({}, { name: `${state.project.name} copy` }, { files: newFiles });
+        axios.post(`${ROOT_URL}/projects`, formParams, { withCredentials: true })
+          .then((response) => {
+            browserHistory.push(`/${response.data.user.username}/sketches/${response.data.id}`);
+            dispatch(setNewProject(response.data));
+          })
+          .catch(response => dispatch({
+            type: ActionTypes.PROJECT_SAVE_FAIL,
+            error: response.data
+          }));
+      });
+    });
+  };
+}
+ 
+export function showEditProjectName() {
+  return {
+    type: ActionTypes.SHOW_EDIT_PROJECT_NAME
+  };
+}
+ 
+export function hideEditProjectName() {
+  return {
+    type: ActionTypes.HIDE_EDIT_PROJECT_NAME
+  };
+}
+ 
+export function setProjectSavedTime(updatedAt) {
+  return {
+    type: ActionTypes.SET_PROJECT_SAVED_TIME,
+    value: updatedAt
+  };
+}
+ 
+export function changeProjectName(id, newName) {
+  return (dispatch, getState) => {
+    const state = getState();
+    axios.put(`${ROOT_URL}/projects/${id}`, { name: newName }, { withCredentials: true })
+      .then((response) => {
+        if (response.status === 200) {
+          dispatch({
+            type: ActionTypes.RENAME_PROJECT,
+            payload: { id: response.data.id, name: response.data.name }
+          });
+          if (state.project.id === response.data.id) {
+            dispatch({
+              type: ActionTypes.SET_PROJECT_NAME,
+              name: response.data.name
+            });
+          }
+        }
+      })
+      .catch((response) => {
+        console.log(response);
+        dispatch({
+          type: ActionTypes.PROJECT_SAVE_FAIL,
+          error: response.data
+        });
+      });
+  };
+}
+ 
+export function deleteProject(id) {
+  return (dispatch, getState) => {
+    axios.delete(`${ROOT_URL}/projects/${id}`, { withCredentials: true })
+      .then(() => {
+        const state = getState();
+        if (id === state.project.id) {
+          dispatch(resetProject());
+          dispatch(setPreviousPath('/'));
+        }
+        dispatch({
+          type: ActionTypes.DELETE_PROJECT,
+          id
+        });
+      })
+      .catch((response) => {
+        if (response.status === 403) {
+          dispatch(showErrorModal('staleSession'));
+        } else {
+          dispatch({
+            type: ActionTypes.ERROR,
+            error: response.data
+          });
+        }
+      });
+  };
+}
+ 
+ +
+
+ + + + + + + + + \ No newline at end of file diff --git a/coverage/lcov-report/client/modules/IDE/actions/toast.js.html b/coverage/lcov-report/client/modules/IDE/actions/toast.js.html new file mode 100644 index 00000000..6301c858 --- /dev/null +++ b/coverage/lcov-report/client/modules/IDE/actions/toast.js.html @@ -0,0 +1,148 @@ + + + + + + Code coverage report for client/modules/IDE/actions/toast.js + + + + + + + + +
+
+

All files / client/modules/IDE/actions toast.js

+
+ +
+ 0% + Statements + 0/6 +
+ + +
+ 100% + Branches + 0/0 +
+ + +
+ 0% + Functions + 0/5 +
+ + +
+ 0% + Lines + 0/5 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  + 
import * as ActionTypes from '../../../constants';
+ 
+export function hideToast() {
+  return {
+    type: ActionTypes.HIDE_TOAST
+  };
+}
+ 
+export function showToast(time) {
+  return (dispatch) => {
+    dispatch({
+      type: ActionTypes.SHOW_TOAST
+    });
+    setTimeout(() => dispatch(hideToast()), time);
+  };
+}
+ 
+export function setToastText(text) {
+  return {
+    type: ActionTypes.SET_TOAST_TEXT,
+    text
+  };
+}
+ 
+ +
+
+ + + + + + + + + \ No newline at end of file diff --git a/coverage/lcov-report/client/modules/IDE/components/FileNode.jsx.html b/coverage/lcov-report/client/modules/IDE/components/FileNode.jsx.html new file mode 100644 index 00000000..bf559df5 --- /dev/null +++ b/coverage/lcov-report/client/modules/IDE/components/FileNode.jsx.html @@ -0,0 +1,1057 @@ + + + + + + Code coverage report for client/modules/IDE/components/FileNode.jsx + + + + + + + + +
+
+

All files / client/modules/IDE/components FileNode.jsx

+
+ +
+ 57.58% + Statements + 57/99 +
+ + +
+ 47.73% + Branches + 21/44 +
+ + +
+ 39.47% + Functions + 15/38 +
+ + +
+ 61.29% + Lines + 57/93 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30 +31 +32 +33 +34 +35 +36 +37 +38 +39 +40 +41 +42 +43 +44 +45 +46 +47 +48 +49 +50 +51 +52 +53 +54 +55 +56 +57 +58 +59 +60 +61 +62 +63 +64 +65 +66 +67 +68 +69 +70 +71 +72 +73 +74 +75 +76 +77 +78 +79 +80 +81 +82 +83 +84 +85 +86 +87 +88 +89 +90 +91 +92 +93 +94 +95 +96 +97 +98 +99 +100 +101 +102 +103 +104 +105 +106 +107 +108 +109 +110 +111 +112 +113 +114 +115 +116 +117 +118 +119 +120 +121 +122 +123 +124 +125 +126 +127 +128 +129 +130 +131 +132 +133 +134 +135 +136 +137 +138 +139 +140 +141 +142 +143 +144 +145 +146 +147 +148 +149 +150 +151 +152 +153 +154 +155 +156 +157 +158 +159 +160 +161 +162 +163 +164 +165 +166 +167 +168 +169 +170 +171 +172 +173 +174 +175 +176 +177 +178 +179 +180 +181 +182 +183 +184 +185 +186 +187 +188 +189 +190 +191 +192 +193 +194 +195 +196 +197 +198 +199 +200 +201 +202 +203 +204 +205 +206 +207 +208 +209 +210 +211 +212 +213 +214 +215 +216 +217 +218 +219 +220 +221 +222 +223 +224 +225 +226 +227 +228 +229 +230 +231 +232 +233 +234 +235 +236 +237 +238 +239 +240 +241 +242 +243 +244 +245 +246 +247 +248 +249 +250 +251 +252 +253 +254 +255 +256 +257 +258 +259 +260 +261 +262 +263 +264 +265 +266 +267 +268 +269 +270 +271 +272 +273 +274 +275 +276 +277 +278 +279 +280 +281 +282 +283 +284 +285 +286 +287 +288 +289 +290 +291 +292 +293 +294 +295 +296 +297 +298 +299 +300 +301 +302 +303 +304 +305 +306 +307 +308 +309 +310 +311 +312 +313 +314 +315 +316 +317 +318 +319 +320 +321 +322 +323 +324 +325 +326 +327  +  +  +  +  +  +  +  +  +1x +1x +1x +1x +  +  +  +3x +3x +3x +3x +3x +3x +3x +3x +3x +3x +3x +3x +  +3x +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +71x +  +  +  +1x +1x +  +1x +1x +  +  +  +  +  +  +  +  +  +  +  +2x +2x +  +  +  +  +  +  +  +  +  +2x +2x +2x +2x +2x +2x +2x +  +2x +2x +2x +1x +1x +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +2x +  +  +  +2x +  +  +  +  +  +  +  +  +  +  +  +13x +  +  +  +  +  +  +  +  +13x +  +  +13x +13x +  +  +  +13x +  +  +  +  +  +  +13x +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +2x +2x +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +13x +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +13x +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +2x +2x +2x +2x +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +13x +13x +  +  +  +  +  +  +  +  +  +  +  +1x +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +1x +  +  +  +  +  +  +  +  +  +  +  +  +  +  +1x +  + 
import PropTypes from 'prop-types';
+import React from 'react';
+import { bindActionCreators } from 'redux';
+import { connect } from 'react-redux';
+import InlineSVG from 'react-inlinesvg';
+import classNames from 'classnames';
+import * as IDEActions from '../actions/ide';
+import * as FileActions from '../actions/files';
+ 
+const downArrowUrl = require('../../../images/down-filled-triangle.svg');
+const folderRightUrl = require('../../../images/triangle-arrow-right.svg');
+const folderDownUrl = require('../../../images/triangle-arrow-down.svg');
+const fileUrl = require('../../../images/file.svg');
+ 
+export class FileNode extends React.Component {
+  constructor(props) {
+    super(props);
+    this.renderChild = this.renderChild.bind(this);
+    this.handleKeyPress = this.handleKeyPress.bind(this);
+    this.handleFileNameChange = this.handleFileNameChange.bind(this);
+    this.validateFileName = this.validateFileName.bind(this);
+    this.handleFileClick = this.handleFileClick.bind(this);
+    this.toggleFileOptions = this.toggleFileOptions.bind(this);
+    this.hideFileOptions = this.hideFileOptions.bind(this);
+    this.showEditFileName = this.showEditFileName.bind(this);
+    this.hideEditFileName = this.hideEditFileName.bind(this);
+    this.onBlurComponent = this.onBlurComponent.bind(this);
+    this.onFocusComponent = this.onFocusComponent.bind(this);
+ 
+    this.state = {
+      isOptionsOpen: false,
+      isEditingName: false,
+      isFocused: false,
+      updatedName: this.props.name
+    };
+  }
+ 
+  onFocusComponent() {
+    this.setState({ isFocused: true });
+  }
+ 
+  onBlurComponent() {
+    this.setState({ isFocused: false });
+    setTimeout(() => {
+      if (!this.state.isFocused) {
+        this.hideFileOptions();
+      }
+    }, 200);
+  }
+ 
+  get updatedName() {
+    return this.state.updatedName;
+  }
+ 
+  commitFileNameChange() {
+    const { updatedName } = this.state;
+    const { name, updateFileName, id } = this.props;
+ 
+    Eif (updatedName !== name) {
+      updateFileName(id, updatedName);
+    }
+  }
+ 
+  handleFileClick(e) {
+    e.stopPropagation();
+    if (this.updatedName !== 'root' && !this.isDeleting) {
+      this.props.setSelectedFile(this.props.id);
+    }
+  }
+ 
+  handleFileNameChange(event) {
+    const newname = event.target.value;
+    this.setState({ updatedName: newname });
+  }
+ 
+  handleKeyPress(event) {
+    if (event.key === 'Enter') {
+      this.hideEditFileName();
+    }
+  }
+ 
+  validateFileName() {
+    const oldFileExtension = this.originalFileName.match(/\.[0-9a-z]+$/i);
+    const newFileExtension = this.updatedName.match(/\.[0-9a-z]+$/i);
+    const hasPeriod = this.updatedName.match(/\.+/);
+    const newFileName = this.updatedName;
+    const hasNoExtension = oldFileExtension && !newFileExtension;
+    const hasExtensionIfFolder = this.props.fileType === 'folder' && hasPeriod;
+    const notSameExtension = oldFileExtension && newFileExtension
+      && oldFileExtension[0].toLowerCase() !== newFileExtension[0].toLowerCase();
+    const hasEmptyFilename = newFileName === '';
+    const hasOnlyExtension = newFileExtension && newFileName === newFileExtension[0];
+    if (hasEmptyFilename || hasNoExtension || notSameExtension || hasOnlyExtension || hasExtensionIfFolder) {
+      this.setState({ updatedName: this.originalFileName });
+    } else this.commitFileNameChange();
+  }
+ 
+  toggleFileOptions(e) {
+    e.preventDefault();
+    if (!this.props.canEdit) {
+      return;
+    }
+    if (this.state.isOptionsOpen) {
+      this.setState({ isOptionsOpen: false });
+    } else {
+      this[`fileOptions-${this.props.id}`].focus();
+      this.setState({ isOptionsOpen: true });
+    }
+  }
+ 
+  hideFileOptions() {
+    this.setState({ isOptionsOpen: false });
+  }
+ 
+  showEditFileName() {
+    this.setState({ isEditingName: true });
+  }
+ 
+  hideEditFileName() {
+    this.setState({ isEditingName: false });
+  }
+ 
+  renderChild(childId) {
+    return (
+      <li key={childId}>
+        <ConnectedFileNode id={childId} parentId={this.props.id} canEdit={this.props.canEdit} />
+      </li>
+    );
+  }
+ 
+  render() {
+    const itemClass = classNames({
+      'sidebar__root-item': this.updatedName === 'root',
+      'sidebar__file-item': this.updatedName !== 'root',
+      'sidebar__file-item--selected': this.props.isSelectedFile,
+      'sidebar__file-item--open': this.state.isOptionsOpen,
+      'sidebar__file-item--editing': this.state.isEditingName,
+      'sidebar__file-item--closed': this.props.isFolderClosed
+    });
+ 
+    return (
+      <div className={itemClass}>
+        {(() => { // eslint-disable-line
+          Eif (this.updatedName !== 'root') {
+            return (
+              <div className="file-item__content" onContextMenu={this.toggleFileOptions}>
+                <span className="file-item__spacer"></span>
+                {(() => { // eslint-disable-line
+                  Iif (this.props.fileType === 'file') {
+                    return (
+                      <span className="sidebar__file-item-icon">
+                        <InlineSVG src={fileUrl} />
+                      </span>
+                    );
+                  }
+                  return (
+                    <div className="sidebar__file-item--folder">
+                      <button
+                        className="sidebar__file-item-closed"
+                        onClick={() => this.props.showFolderChildren(this.props.id)}
+                      >
+                        <InlineSVG className="folder-right" src={folderRightUrl} />
+                      </button>
+                      <button
+                        className="sidebar__file-item-open"
+                        onClick={() => this.props.hideFolderChildren(this.props.id)}
+                      >
+                        <InlineSVG className="folder-down" src={folderDownUrl} />
+                      </button>
+                    </div>
+                  );
+                })()}
+                <button className="sidebar__file-item-name" onClick={this.handleFileClick}>{this.updatedName}</button>
+                <input
+                  type="text"
+                  className="sidebar__file-item-input"
+                  value={this.updatedName}
+                  maxLength="128"
+                  onChange={this.handleFileNameChange}
+                  ref={(element) => { this.fileNameInput = element; }}
+                  onBlur={() => {
+                    this.validateFileName();
+                    this.hideEditFileName();
+                  }}
+                  onKeyPress={this.handleKeyPress}
+                />
+                <button
+                  className="sidebar__file-item-show-options"
+                  aria-label="view file options"
+                  ref={(element) => { this[`fileOptions-${this.props.id}`] = element; }}
+                  tabIndex="0"
+                  onClick={this.toggleFileOptions}
+                  onBlur={this.onBlurComponent}
+                  onFocus={this.onFocusComponent}
+                >
+                  <InlineSVG src={downArrowUrl} />
+                </button>
+                <div className="sidebar__file-item-options">
+                  <ul title="file options">
+                    {(() => { // eslint-disable-line
+                      Iif (this.props.fileType === 'folder') {
+                        return (
+                          <li>
+                            <button
+                              aria-label="add file"
+                              onClick={() => {
+                                this.props.newFile(this.props.id);
+                                setTimeout(() => this.hideFileOptions(), 0);
+                              }}
+                              onBlur={this.onBlurComponent}
+                              onFocus={this.onFocusComponent}
+                              className="sidebar__file-item-option"
+                            >
+                              Add File
+                            </button>
+                          </li>
+                        );
+                      }
+                    })()}
+                    {(() => { // eslint-disable-line
+                      Iif (this.props.fileType === 'folder') {
+                        return (
+                          <li>
+                            <button
+                              aria-label="add folder"
+                              onClick={() => {
+                                this.props.newFolder(this.props.id);
+                                setTimeout(() => this.hideFileOptions(), 0);
+                              }}
+                              onBlur={this.onBlurComponent}
+                              onFocus={this.onFocusComponent}
+                              className="sidebar__file-item-option"
+                            >
+                              Add Folder
+                            </button>
+                          </li>
+                        );
+                      }
+                    })()}
+                    <li>
+                      <button
+                        onClick={() => {
+                          this.originalFileName = this.props.name;
+                          this.showEditFileName();
+                          setTimeout(() => this.fileNameInput.focus(), 0);
+                          setTimeout(() => this.hideFileOptions(), 0);
+                        }}
+                        onBlur={this.onBlurComponent}
+                        onFocus={this.onFocusComponent}
+                        className="sidebar__file-item-option"
+                      >
+                        Rename
+                      </button>
+                    </li>
+                    <li>
+                      <button
+                        onClick={() => {
+                          if (window.confirm(`Are you sure you want to delete ${this.updatedName}?`)) {
+                            this.isDeleting = true;
+                            this.props.resetSelectedFile(this.props.id);
+                            setTimeout(() => this.props.deleteFile(this.props.id, this.props.parentId), 100);
+                          }
+                        }}
+                        onBlur={this.onBlurComponent}
+                        onFocus={this.onFocusComponent}
+                        className="sidebar__file-item-option"
+                      >
+                        Delete
+                      </button>
+                    </li>
+                  </ul>
+                </div>
+              </div>
+            );
+          }
+        })()}
+        {(() => { // eslint-disable-line
+          Eif (this.props.children) {
+            return (
+              <ul className="file-item__children">
+                {this.props.children.map(this.renderChild)}
+              </ul>
+            );
+          }
+        })()}
+      </div>
+    );
+  }
+}
+ 
+FileNode.propTypes = {
+  id: PropTypes.string.isRequired,
+  parentId: PropTypes.string,
+  children: PropTypes.arrayOf(PropTypes.string.isRequired).isRequired,
+  name: PropTypes.string.isRequired,
+  fileType: PropTypes.string.isRequired,
+  isSelectedFile: PropTypes.bool,
+  isFolderClosed: PropTypes.bool,
+  setSelectedFile: PropTypes.func.isRequired,
+  deleteFile: PropTypes.func.isRequired,
+  updateFileName: PropTypes.func.isRequired,
+  resetSelectedFile: PropTypes.func.isRequired,
+  newFile: PropTypes.func.isRequired,
+  newFolder: PropTypes.func.isRequired,
+  showFolderChildren: PropTypes.func.isRequired,
+  hideFolderChildren: PropTypes.func.isRequired,
+  canEdit: PropTypes.bool.isRequired
+};
+ 
+FileNode.defaultProps = {
+  parentId: '0',
+  isSelectedFile: false,
+  isFolderClosed: false,
+};
+ 
+function mapStateToProps(state, ownProps) {
+  // this is a hack, state is updated before ownProps
+  return state.files.find(file => file.id === ownProps.id) || { name: 'test', fileType: 'file' };
+}
+ 
+function mapDispatchToProps(dispatch) {
+  return bindActionCreators(Object.assign(FileActions, IDEActions), dispatch);
+}
+ 
+const ConnectedFileNode = connect(mapStateToProps, mapDispatchToProps)(FileNode);
+export default ConnectedFileNode;
+ 
+ +
+
+ + + + + + + + + \ No newline at end of file diff --git a/coverage/lcov-report/client/modules/IDE/components/index.html b/coverage/lcov-report/client/modules/IDE/components/index.html new file mode 100644 index 00000000..97c78eb8 --- /dev/null +++ b/coverage/lcov-report/client/modules/IDE/components/index.html @@ -0,0 +1,110 @@ + + + + + + Code coverage report for client/modules/IDE/components + + + + + + + + +
+
+

All files client/modules/IDE/components

+
+ +
+ 57.58% + Statements + 57/99 +
+ + +
+ 47.73% + Branches + 21/44 +
+ + +
+ 39.47% + Functions + 15/38 +
+ + +
+ 61.29% + Lines + 57/93 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+
+
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
FileStatementsBranchesFunctionsLines
FileNode.jsx +
+
57.58%57/9947.73%21/4439.47%15/3861.29%57/93
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/coverage/lcov-report/client/modules/User/actions.js.html b/coverage/lcov-report/client/modules/User/actions.js.html new file mode 100644 index 00000000..456d963c --- /dev/null +++ b/coverage/lcov-report/client/modules/User/actions.js.html @@ -0,0 +1,823 @@ + + + + + + Code coverage report for client/modules/User/actions.js + + + + + + + + +
+
+

All files / client/modules/User actions.js

+
+ +
+ 2.63% + Statements + 2/76 +
+ + +
+ 12.5% + Branches + 1/8 +
+ + +
+ 0% + Functions + 0/59 +
+ + +
+ 2.63% + Lines + 2/76 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30 +31 +32 +33 +34 +35 +36 +37 +38 +39 +40 +41 +42 +43 +44 +45 +46 +47 +48 +49 +50 +51 +52 +53 +54 +55 +56 +57 +58 +59 +60 +61 +62 +63 +64 +65 +66 +67 +68 +69 +70 +71 +72 +73 +74 +75 +76 +77 +78 +79 +80 +81 +82 +83 +84 +85 +86 +87 +88 +89 +90 +91 +92 +93 +94 +95 +96 +97 +98 +99 +100 +101 +102 +103 +104 +105 +106 +107 +108 +109 +110 +111 +112 +113 +114 +115 +116 +117 +118 +119 +120 +121 +122 +123 +124 +125 +126 +127 +128 +129 +130 +131 +132 +133 +134 +135 +136 +137 +138 +139 +140 +141 +142 +143 +144 +145 +146 +147 +148 +149 +150 +151 +152 +153 +154 +155 +156 +157 +158 +159 +160 +161 +162 +163 +164 +165 +166 +167 +168 +169 +170 +171 +172 +173 +174 +175 +176 +177 +178 +179 +180 +181 +182 +183 +184 +185 +186 +187 +188 +189 +190 +191 +192 +193 +194 +195 +196 +197 +198 +199 +200 +201 +202 +203 +204 +205 +206 +207 +208 +209 +210 +211 +212 +213 +214 +215 +216 +217 +218 +219 +220 +221 +222 +223 +224 +225 +226 +227 +228 +229 +230 +231 +232 +233 +234 +235 +236 +237 +238 +239 +240 +241 +242 +243 +244 +245 +246 +247 +248 +249  +  +  +  +  +  +  +1x +1x +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  + 
import { browserHistory } from 'react-router';
+import axios from 'axios';
+import * as ActionTypes from '../../constants';
+import { showErrorModal, justOpenedProject } from '../IDE/actions/ide';
+import { showToast, setToastText } from '../IDE/actions/toast';
+ 
+ 
+const __process = (typeof global !== 'undefined' ? global : window).process;
+const ROOT_URL = __process.env.API_URL;
+ 
+export function authError(error) {
+  return {
+    type: ActionTypes.AUTH_ERROR,
+    payload: error
+  };
+}
+ 
+export function signUpUser(previousPath, formValues) {
+  return (dispatch) => {
+    axios.post(`${ROOT_URL}/signup`, formValues, { withCredentials: true })
+      .then((response) => {
+        dispatch({
+          type: ActionTypes.AUTH_USER,
+          user: response.data
+        });
+        dispatch(justOpenedProject());
+        browserHistory.push(previousPath);
+      })
+      .catch(response => dispatch(authError(response.data.error)));
+  };
+}
+ 
+export function loginUser(formValues) {
+  return axios.post(`${ROOT_URL}/login`, formValues, { withCredentials: true });
+}
+ 
+export function loginUserSuccess(user) {
+  return {
+    type: ActionTypes.AUTH_USER,
+    user
+  };
+}
+ 
+export function loginUserFailure(error) {
+  return {
+    type: ActionTypes.AUTH_ERROR,
+    error
+  };
+}
+ 
+export function validateAndLoginUser(previousPath, formProps, dispatch) {
+  return new Promise((resolve, reject) => {
+    loginUser(formProps)
+      .then((response) => {
+        dispatch({
+          type: ActionTypes.AUTH_USER,
+          user: response.data
+        });
+        dispatch({
+          type: ActionTypes.SET_PREFERENCES,
+          preferences: response.data.preferences
+        });
+        dispatch(justOpenedProject());
+        browserHistory.push(previousPath);
+        resolve();
+      })
+      .catch(error =>
+        reject({ password: error.response.data.message, _error: 'Login failed!' })); // eslint-disable-line
+  });
+}
+ 
+export function getUser() {
+  return (dispatch) => {
+    axios.get(`${ROOT_URL}/session`, { withCredentials: true })
+      .then((response) => {
+        dispatch({
+          type: ActionTypes.AUTH_USER,
+          user: response.data
+        });
+        dispatch({
+          type: ActionTypes.SET_PREFERENCES,
+          preferences: response.data.preferences
+        });
+      })
+      .catch((response) => {
+        const message = response.message || response.data.error;
+        dispatch(authError(message));
+      });
+  };
+}
+ 
+export function validateSession() {
+  return (dispatch, getState) => {
+    axios.get(`${ROOT_URL}/session`, { withCredentials: true })
+      .then((response) => {
+        const state = getState();
+        if (state.user.username !== response.data.username) {
+          dispatch(showErrorModal('staleSession'));
+        }
+      })
+      .catch((response) => {
+        if (response.status === 404) {
+          dispatch(showErrorModal('staleSession'));
+        }
+      });
+  };
+}
+ 
+export function logoutUser() {
+  return (dispatch) => {
+    axios.get(`${ROOT_URL}/logout`, { withCredentials: true })
+      .then(() => {
+        dispatch({
+          type: ActionTypes.UNAUTH_USER
+        });
+      })
+      .catch(response => dispatch(authError(response.data.error)));
+  };
+}
+ 
+export function initiateResetPassword(formValues) {
+  return (dispatch) => {
+    dispatch({
+      type: ActionTypes.RESET_PASSWORD_INITIATE
+    });
+    axios.post(`${ROOT_URL}/reset-password`, formValues, { withCredentials: true })
+      .then(() => {
+        // do nothing
+      })
+      .catch(response => dispatch({
+        type: ActionTypes.ERROR,
+        message: response.data
+      }));
+  };
+}
+ 
+export function initiateVerification() {
+  return (dispatch) => {
+    dispatch({
+      type: ActionTypes.EMAIL_VERIFICATION_INITIATE
+    });
+    axios.post(`${ROOT_URL}/verify/send`, {}, { withCredentials: true })
+      .then(() => {
+        // do nothing
+      })
+      .catch(response => dispatch({
+        type: ActionTypes.ERROR,
+        message: response.data
+      }));
+  };
+}
+ 
+export function verifyEmailConfirmation(token) {
+  return (dispatch) => {
+    dispatch({
+      type: ActionTypes.EMAIL_VERIFICATION_VERIFY,
+      state: 'checking',
+    });
+    return axios.get(`${ROOT_URL}/verify?t=${token}`, {}, { withCredentials: true })
+      .then(response => dispatch({
+        type: ActionTypes.EMAIL_VERIFICATION_VERIFIED,
+        message: response.data,
+      }))
+      .catch(response => dispatch({
+        type: ActionTypes.EMAIL_VERIFICATION_INVALID,
+        message: response.data
+      }));
+  };
+}
+ 
+ 
+export function resetPasswordReset() {
+  return {
+    type: ActionTypes.RESET_PASSWORD_RESET
+  };
+}
+ 
+export function validateResetPasswordToken(token) {
+  return (dispatch) => {
+    axios.get(`${ROOT_URL}/reset-password/${token}`)
+      .then(() => {
+        // do nothing if the token is valid
+      })
+      .catch(() => dispatch({
+        type: ActionTypes.INVALID_RESET_PASSWORD_TOKEN
+      }));
+  };
+}
+ 
+export function updatePassword(token, formValues) {
+  return (dispatch) => {
+    axios.post(`${ROOT_URL}/reset-password/${token}`, formValues)
+      .then((response) => {
+        dispatch(loginUserSuccess(response.data));
+        browserHistory.push('/');
+      })
+      .catch(() => dispatch({
+        type: ActionTypes.INVALID_RESET_PASSWORD_TOKEN
+      }));
+  };
+}
+ 
+export function updateSettingsSuccess(user) {
+  return {
+    type: ActionTypes.SETTINGS_UPDATED,
+    user
+  };
+}
+ 
+export function updateSettings(formValues) {
+  return dispatch =>
+    axios.put(`${ROOT_URL}/account`, formValues, { withCredentials: true })
+      .then((response) => {
+        dispatch(updateSettingsSuccess(response.data));
+        browserHistory.push('/');
+        dispatch(showToast(5500));
+        dispatch(setToastText('Settings saved.'));
+      })
+      .catch(response => Promise.reject(new Error(response.data.error)));
+}
+ 
+export function createApiKeySuccess(user) {
+  return {
+    type: ActionTypes.API_KEY_CREATED,
+    user
+  };
+}
+ 
+export function createApiKey(label) {
+  return dispatch =>
+    axios.post(`${ROOT_URL}/account/api-keys`, { label }, { withCredentials: true })
+      .then((response) => {
+        dispatch(createApiKeySuccess(response.data));
+      })
+      .catch(response => Promise.reject(new Error(response.data.error)));
+}
+ 
+export function removeApiKey(keyId) {
+  return dispatch =>
+    axios.delete(`${ROOT_URL}/account/api-keys/${keyId}`, { withCredentials: true })
+      .then((response) => {
+        dispatch({
+          type: ActionTypes.API_KEY_REMOVED,
+          user: response.data
+        });
+      })
+      .catch(response => Promise.reject(new Error(response.data.error)));
+}
+ 
+ +
+
+ + + + + + + + + \ No newline at end of file diff --git a/coverage/lcov-report/client/modules/User/index.html b/coverage/lcov-report/client/modules/User/index.html new file mode 100644 index 00000000..f6772893 --- /dev/null +++ b/coverage/lcov-report/client/modules/User/index.html @@ -0,0 +1,110 @@ + + + + + + Code coverage report for client/modules/User + + + + + + + + +
+
+

All files client/modules/User

+
+ +
+ 2.63% + Statements + 2/76 +
+ + +
+ 12.5% + Branches + 1/8 +
+ + +
+ 0% + Functions + 0/59 +
+ + +
+ 2.63% + Lines + 2/76 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+
+
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
FileStatementsBranchesFunctionsLines
actions.js +
+
2.63%2/7612.5%1/80%0/592.63%2/76
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/coverage/lcov-report/client/persistState.js.html b/coverage/lcov-report/client/persistState.js.html new file mode 100644 index 00000000..6ebce6dc --- /dev/null +++ b/coverage/lcov-report/client/persistState.js.html @@ -0,0 +1,160 @@ + + + + + + Code coverage report for client/persistState.js + + + + + + + + +
+
+

All files / client persistState.js

+
+ +
+ 38.46% + Statements + 5/13 +
+ + +
+ 100% + Branches + 0/0 +
+ + +
+ 0% + Functions + 0/3 +
+ + +
+ 38.46% + Lines + 5/13 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28  +  +  +  +2x +2x +  +2x +  +  +  +  +  +  +  +2x +  +  +  +  +  +  +  +  +2x +  +  + 
/*
+  Saves and loads a snapshot of the Redux store
+  state to session storage
+*/
+const key = 'p5js-editor';
+const storage = sessionStorage;
+ 
+export const saveState = (state) => {
+  try {
+    storage.setItem(key, JSON.stringify(state));
+  } catch (error) {
+    console.warn('Unable to persist state to storage:', error);
+  }
+};
+ 
+export const loadState = () => {
+  try {
+    return JSON.parse(storage.getItem(key));
+  } catch (error) {
+    console.warn('Failed to retrieve initialize state from storage:', error);
+    return null;
+  }
+};
+ 
+export const clearState = () => {
+  storage.removeItem(key);
+};
+ 
+ +
+
+ + + + + + + + + \ No newline at end of file diff --git a/coverage/lcov-report/client/utils/index.html b/coverage/lcov-report/client/utils/index.html new file mode 100644 index 00000000..59a2b96e --- /dev/null +++ b/coverage/lcov-report/client/utils/index.html @@ -0,0 +1,110 @@ + + + + + + Code coverage report for client/utils + + + + + + + + +
+
+

All files client/utils

+
+ +
+ 80% + Statements + 4/5 +
+ + +
+ 62.5% + Branches + 5/8 +
+ + +
+ 100% + Functions + 1/1 +
+ + +
+ 80% + Lines + 4/5 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+
+
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
FileStatementsBranchesFunctionsLines
metaKey.js +
+
80%4/562.5%5/8100%1/180%4/5
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/coverage/lcov-report/client/utils/metaKey.js.html b/coverage/lcov-report/client/utils/metaKey.js.html new file mode 100644 index 00000000..c1d3cc7d --- /dev/null +++ b/coverage/lcov-report/client/utils/metaKey.js.html @@ -0,0 +1,127 @@ + + + + + + Code coverage report for client/utils/metaKey.js + + + + + + + + +
+
+

All files / client/utils metaKey.js

+
+ +
+ 80% + Statements + 4/5 +
+ + +
+ 62.5% + Branches + 5/8 +
+ + +
+ 100% + Functions + 1/1 +
+ + +
+ 80% + Lines + 4/5 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +171x +1x +1x +  +  +  +  +  +  +  +1x +  +  +  +  +  + 
const metaKey = (() => {
+  Eif (navigator != null && navigator.platform != null) {
+    return /^MAC/i.test(navigator.platform) ?
+      'Cmd' :
+      'Ctrl';
+  }
+ 
+  return 'Ctrl';
+})();
+ 
+const metaKeyName = metaKey === 'Cmd' ? '\u2318' : 'Ctrl';
+ 
+export {
+  metaKey,
+  metaKeyName,
+};
+ 
+ +
+
+ + + + + + + + + \ No newline at end of file diff --git a/coverage/lcov-report/index.html b/coverage/lcov-report/index.html new file mode 100644 index 00000000..7d8442c2 --- /dev/null +++ b/coverage/lcov-report/index.html @@ -0,0 +1,275 @@ + + + + + + Code coverage report for All files + + + + + + + + +
+
+

All files

+
+ +
+ 40.38% + Statements + 441/1092 +
+ + +
+ 32.01% + Branches + 105/328 +
+ + +
+ 19.74% + Functions + 77/390 +
+ + +
+ 41.38% + Lines + 439/1061 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+
+
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
FileStatementsBranchesFunctionsLines
client +
+
93.44%114/122100%0/00%0/393.44%114/122
client/__test__/mocks +
+
100%1/1100%0/0100%0/0100%1/1
client/components +
+
38.85%54/13928.79%19/6615.91%7/4438.85%54/139
client/modules/IDE/actions +
+
1.63%6/3683.03%3/990%0/1671.69%6/354
client/modules/IDE/components +
+
57.58%57/9947.73%21/4439.47%15/3861.29%57/93
client/modules/User +
+
2.63%2/7612.5%1/80%0/592.63%2/76
client/utils +
+
80%4/562.5%5/8100%1/180%4/5
server/controllers/project.controller +
+
79.55%70/8868.42%26/3876.67%23/3080.46%70/87
server/controllers/user.controller +
+
86%43/5072.22%13/18100%15/1585.71%42/49
server/domain-objects +
+
97.96%48/4987.5%14/1688.89%8/997.92%47/48
server/models +
+
37.65%32/853.57%1/2820%4/2041.56%32/77
server/utils +
+
100%10/1066.67%2/3100%4/4100%10/10
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/coverage/lcov-report/prettify.css b/coverage/lcov-report/prettify.css new file mode 100644 index 00000000..b317a7cd --- /dev/null +++ b/coverage/lcov-report/prettify.css @@ -0,0 +1 @@ +.pln{color:#000}@media screen{.str{color:#080}.kwd{color:#008}.com{color:#800}.typ{color:#606}.lit{color:#066}.pun,.opn,.clo{color:#660}.tag{color:#008}.atn{color:#606}.atv{color:#080}.dec,.var{color:#606}.fun{color:red}}@media print,projection{.str{color:#060}.kwd{color:#006;font-weight:bold}.com{color:#600;font-style:italic}.typ{color:#404;font-weight:bold}.lit{color:#044}.pun,.opn,.clo{color:#440}.tag{color:#006;font-weight:bold}.atn{color:#404}.atv{color:#060}}pre.prettyprint{padding:2px;border:1px solid #888}ol.linenums{margin-top:0;margin-bottom:0}li.L0,li.L1,li.L2,li.L3,li.L5,li.L6,li.L7,li.L8{list-style-type:none}li.L1,li.L3,li.L5,li.L7,li.L9{background:#eee} diff --git a/coverage/lcov-report/prettify.js b/coverage/lcov-report/prettify.js new file mode 100644 index 00000000..b3225238 --- /dev/null +++ b/coverage/lcov-report/prettify.js @@ -0,0 +1,2 @@ +/* eslint-disable */ +window.PR_SHOULD_USE_CONTINUATION=true;(function(){var h=["break,continue,do,else,for,if,return,while"];var u=[h,"auto,case,char,const,default,double,enum,extern,float,goto,int,long,register,short,signed,sizeof,static,struct,switch,typedef,union,unsigned,void,volatile"];var p=[u,"catch,class,delete,false,import,new,operator,private,protected,public,this,throw,true,try,typeof"];var l=[p,"alignof,align_union,asm,axiom,bool,concept,concept_map,const_cast,constexpr,decltype,dynamic_cast,explicit,export,friend,inline,late_check,mutable,namespace,nullptr,reinterpret_cast,static_assert,static_cast,template,typeid,typename,using,virtual,where"];var x=[p,"abstract,boolean,byte,extends,final,finally,implements,import,instanceof,null,native,package,strictfp,super,synchronized,throws,transient"];var R=[x,"as,base,by,checked,decimal,delegate,descending,dynamic,event,fixed,foreach,from,group,implicit,in,interface,internal,into,is,lock,object,out,override,orderby,params,partial,readonly,ref,sbyte,sealed,stackalloc,string,select,uint,ulong,unchecked,unsafe,ushort,var"];var r="all,and,by,catch,class,else,extends,false,finally,for,if,in,is,isnt,loop,new,no,not,null,of,off,on,or,return,super,then,true,try,unless,until,when,while,yes";var w=[p,"debugger,eval,export,function,get,null,set,undefined,var,with,Infinity,NaN"];var s="caller,delete,die,do,dump,elsif,eval,exit,foreach,for,goto,if,import,last,local,my,next,no,our,print,package,redo,require,sub,undef,unless,until,use,wantarray,while,BEGIN,END";var I=[h,"and,as,assert,class,def,del,elif,except,exec,finally,from,global,import,in,is,lambda,nonlocal,not,or,pass,print,raise,try,with,yield,False,True,None"];var f=[h,"alias,and,begin,case,class,def,defined,elsif,end,ensure,false,in,module,next,nil,not,or,redo,rescue,retry,self,super,then,true,undef,unless,until,when,yield,BEGIN,END"];var H=[h,"case,done,elif,esac,eval,fi,function,in,local,set,then,until"];var A=[l,R,w,s+I,f,H];var e=/^(DIR|FILE|vector|(de|priority_)?queue|list|stack|(const_)?iterator|(multi)?(set|map)|bitset|u?(int|float)\d*)/;var C="str";var z="kwd";var j="com";var O="typ";var G="lit";var L="pun";var F="pln";var m="tag";var E="dec";var J="src";var P="atn";var n="atv";var N="nocode";var M="(?:^^\\.?|[+-]|\\!|\\!=|\\!==|\\#|\\%|\\%=|&|&&|&&=|&=|\\(|\\*|\\*=|\\+=|\\,|\\-=|\\->|\\/|\\/=|:|::|\\;|<|<<|<<=|<=|=|==|===|>|>=|>>|>>=|>>>|>>>=|\\?|\\@|\\[|\\^|\\^=|\\^\\^|\\^\\^=|\\{|\\||\\|=|\\|\\||\\|\\|=|\\~|break|case|continue|delete|do|else|finally|instanceof|return|throw|try|typeof)\\s*";function k(Z){var ad=0;var S=false;var ac=false;for(var V=0,U=Z.length;V122)){if(!(al<65||ag>90)){af.push([Math.max(65,ag)|32,Math.min(al,90)|32])}if(!(al<97||ag>122)){af.push([Math.max(97,ag)&~32,Math.min(al,122)&~32])}}}}af.sort(function(av,au){return(av[0]-au[0])||(au[1]-av[1])});var ai=[];var ap=[NaN,NaN];for(var ar=0;arat[0]){if(at[1]+1>at[0]){an.push("-")}an.push(T(at[1]))}}an.push("]");return an.join("")}function W(al){var aj=al.source.match(new RegExp("(?:\\[(?:[^\\x5C\\x5D]|\\\\[\\s\\S])*\\]|\\\\u[A-Fa-f0-9]{4}|\\\\x[A-Fa-f0-9]{2}|\\\\[0-9]+|\\\\[^ux0-9]|\\(\\?[:!=]|[\\(\\)\\^]|[^\\x5B\\x5C\\(\\)\\^]+)","g"));var ah=aj.length;var an=[];for(var ak=0,am=0;ak=2&&ai==="["){aj[ak]=X(ag)}else{if(ai!=="\\"){aj[ak]=ag.replace(/[a-zA-Z]/g,function(ao){var ap=ao.charCodeAt(0);return"["+String.fromCharCode(ap&~32,ap|32)+"]"})}}}}return aj.join("")}var aa=[];for(var V=0,U=Z.length;V=0;){S[ac.charAt(ae)]=Y}}var af=Y[1];var aa=""+af;if(!ag.hasOwnProperty(aa)){ah.push(af);ag[aa]=null}}ah.push(/[\0-\uffff]/);V=k(ah)})();var X=T.length;var W=function(ah){var Z=ah.sourceCode,Y=ah.basePos;var ad=[Y,F];var af=0;var an=Z.match(V)||[];var aj={};for(var ae=0,aq=an.length;ae=5&&"lang-"===ap.substring(0,5);if(am&&!(ai&&typeof ai[1]==="string")){am=false;ap=J}if(!am){aj[ag]=ap}}var ab=af;af+=ag.length;if(!am){ad.push(Y+ab,ap)}else{var al=ai[1];var ak=ag.indexOf(al);var ac=ak+al.length;if(ai[2]){ac=ag.length-ai[2].length;ak=ac-al.length}var ar=ap.substring(5);B(Y+ab,ag.substring(0,ak),W,ad);B(Y+ab+ak,al,q(ar,al),ad);B(Y+ab+ac,ag.substring(ac),W,ad)}}ah.decorations=ad};return W}function i(T){var W=[],S=[];if(T.tripleQuotedStrings){W.push([C,/^(?:\'\'\'(?:[^\'\\]|\\[\s\S]|\'{1,2}(?=[^\']))*(?:\'\'\'|$)|\"\"\"(?:[^\"\\]|\\[\s\S]|\"{1,2}(?=[^\"]))*(?:\"\"\"|$)|\'(?:[^\\\']|\\[\s\S])*(?:\'|$)|\"(?:[^\\\"]|\\[\s\S])*(?:\"|$))/,null,"'\""])}else{if(T.multiLineStrings){W.push([C,/^(?:\'(?:[^\\\']|\\[\s\S])*(?:\'|$)|\"(?:[^\\\"]|\\[\s\S])*(?:\"|$)|\`(?:[^\\\`]|\\[\s\S])*(?:\`|$))/,null,"'\"`"])}else{W.push([C,/^(?:\'(?:[^\\\'\r\n]|\\.)*(?:\'|$)|\"(?:[^\\\"\r\n]|\\.)*(?:\"|$))/,null,"\"'"])}}if(T.verbatimStrings){S.push([C,/^@\"(?:[^\"]|\"\")*(?:\"|$)/,null])}var Y=T.hashComments;if(Y){if(T.cStyleComments){if(Y>1){W.push([j,/^#(?:##(?:[^#]|#(?!##))*(?:###|$)|.*)/,null,"#"])}else{W.push([j,/^#(?:(?:define|elif|else|endif|error|ifdef|include|ifndef|line|pragma|undef|warning)\b|[^\r\n]*)/,null,"#"])}S.push([C,/^<(?:(?:(?:\.\.\/)*|\/?)(?:[\w-]+(?:\/[\w-]+)+)?[\w-]+\.h|[a-z]\w*)>/,null])}else{W.push([j,/^#[^\r\n]*/,null,"#"])}}if(T.cStyleComments){S.push([j,/^\/\/[^\r\n]*/,null]);S.push([j,/^\/\*[\s\S]*?(?:\*\/|$)/,null])}if(T.regexLiterals){var X=("/(?=[^/*])(?:[^/\\x5B\\x5C]|\\x5C[\\s\\S]|\\x5B(?:[^\\x5C\\x5D]|\\x5C[\\s\\S])*(?:\\x5D|$))+/");S.push(["lang-regex",new RegExp("^"+M+"("+X+")")])}var V=T.types;if(V){S.push([O,V])}var U=(""+T.keywords).replace(/^ | $/g,"");if(U.length){S.push([z,new RegExp("^(?:"+U.replace(/[\s,]+/g,"|")+")\\b"),null])}W.push([F,/^\s+/,null," \r\n\t\xA0"]);S.push([G,/^@[a-z_$][a-z_$@0-9]*/i,null],[O,/^(?:[@_]?[A-Z]+[a-z][A-Za-z_$@0-9]*|\w+_t\b)/,null],[F,/^[a-z_$][a-z_$@0-9]*/i,null],[G,new RegExp("^(?:0x[a-f0-9]+|(?:\\d(?:_\\d+)*\\d*(?:\\.\\d*)?|\\.\\d\\+)(?:e[+\\-]?\\d+)?)[a-z]*","i"),null,"0123456789"],[F,/^\\[\s\S]?/,null],[L,/^.[^\s\w\.$@\'\"\`\/\#\\]*/,null]);return g(W,S)}var K=i({keywords:A,hashComments:true,cStyleComments:true,multiLineStrings:true,regexLiterals:true});function Q(V,ag){var U=/(?:^|\s)nocode(?:\s|$)/;var ab=/\r\n?|\n/;var ac=V.ownerDocument;var S;if(V.currentStyle){S=V.currentStyle.whiteSpace}else{if(window.getComputedStyle){S=ac.defaultView.getComputedStyle(V,null).getPropertyValue("white-space")}}var Z=S&&"pre"===S.substring(0,3);var af=ac.createElement("LI");while(V.firstChild){af.appendChild(V.firstChild)}var W=[af];function ae(al){switch(al.nodeType){case 1:if(U.test(al.className)){break}if("BR"===al.nodeName){ad(al);if(al.parentNode){al.parentNode.removeChild(al)}}else{for(var an=al.firstChild;an;an=an.nextSibling){ae(an)}}break;case 3:case 4:if(Z){var am=al.nodeValue;var aj=am.match(ab);if(aj){var ai=am.substring(0,aj.index);al.nodeValue=ai;var ah=am.substring(aj.index+aj[0].length);if(ah){var ak=al.parentNode;ak.insertBefore(ac.createTextNode(ah),al.nextSibling)}ad(al);if(!ai){al.parentNode.removeChild(al)}}}break}}function ad(ak){while(!ak.nextSibling){ak=ak.parentNode;if(!ak){return}}function ai(al,ar){var aq=ar?al.cloneNode(false):al;var ao=al.parentNode;if(ao){var ap=ai(ao,1);var an=al.nextSibling;ap.appendChild(aq);for(var am=an;am;am=an){an=am.nextSibling;ap.appendChild(am)}}return aq}var ah=ai(ak.nextSibling,0);for(var aj;(aj=ah.parentNode)&&aj.nodeType===1;){ah=aj}W.push(ah)}for(var Y=0;Y=S){ah+=2}if(V>=ap){Z+=2}}}var t={};function c(U,V){for(var S=V.length;--S>=0;){var T=V[S];if(!t.hasOwnProperty(T)){t[T]=U}else{if(window.console){console.warn("cannot override language handler %s",T)}}}}function q(T,S){if(!(T&&t.hasOwnProperty(T))){T=/^\s*]*(?:>|$)/],[j,/^<\!--[\s\S]*?(?:-\->|$)/],["lang-",/^<\?([\s\S]+?)(?:\?>|$)/],["lang-",/^<%([\s\S]+?)(?:%>|$)/],[L,/^(?:<[%?]|[%?]>)/],["lang-",/^]*>([\s\S]+?)<\/xmp\b[^>]*>/i],["lang-js",/^]*>([\s\S]*?)(<\/script\b[^>]*>)/i],["lang-css",/^]*>([\s\S]*?)(<\/style\b[^>]*>)/i],["lang-in.tag",/^(<\/?[a-z][^<>]*>)/i]]),["default-markup","htm","html","mxml","xhtml","xml","xsl"]);c(g([[F,/^[\s]+/,null," \t\r\n"],[n,/^(?:\"[^\"]*\"?|\'[^\']*\'?)/,null,"\"'"]],[[m,/^^<\/?[a-z](?:[\w.:-]*\w)?|\/?>$/i],[P,/^(?!style[\s=]|on)[a-z](?:[\w:-]*\w)?/i],["lang-uq.val",/^=\s*([^>\'\"\s]*(?:[^>\'\"\s\/]|\/(?=\s)))/],[L,/^[=<>\/]+/],["lang-js",/^on\w+\s*=\s*\"([^\"]+)\"/i],["lang-js",/^on\w+\s*=\s*\'([^\']+)\'/i],["lang-js",/^on\w+\s*=\s*([^\"\'>\s]+)/i],["lang-css",/^style\s*=\s*\"([^\"]+)\"/i],["lang-css",/^style\s*=\s*\'([^\']+)\'/i],["lang-css",/^style\s*=\s*([^\"\'>\s]+)/i]]),["in.tag"]);c(g([],[[n,/^[\s\S]+/]]),["uq.val"]);c(i({keywords:l,hashComments:true,cStyleComments:true,types:e}),["c","cc","cpp","cxx","cyc","m"]);c(i({keywords:"null,true,false"}),["json"]);c(i({keywords:R,hashComments:true,cStyleComments:true,verbatimStrings:true,types:e}),["cs"]);c(i({keywords:x,cStyleComments:true}),["java"]);c(i({keywords:H,hashComments:true,multiLineStrings:true}),["bsh","csh","sh"]);c(i({keywords:I,hashComments:true,multiLineStrings:true,tripleQuotedStrings:true}),["cv","py"]);c(i({keywords:s,hashComments:true,multiLineStrings:true,regexLiterals:true}),["perl","pl","pm"]);c(i({keywords:f,hashComments:true,multiLineStrings:true,regexLiterals:true}),["rb"]);c(i({keywords:w,cStyleComments:true,regexLiterals:true}),["js"]);c(i({keywords:r,hashComments:3,cStyleComments:true,multilineStrings:true,tripleQuotedStrings:true,regexLiterals:true}),["coffee"]);c(g([],[[C,/^[\s\S]+/]]),["regex"]);function d(V){var U=V.langExtension;try{var S=a(V.sourceNode);var T=S.sourceCode;V.sourceCode=T;V.spans=S.spans;V.basePos=0;q(U,T)(V);D(V)}catch(W){if("console" in window){console.log(W&&W.stack?W.stack:W)}}}function y(W,V,U){var S=document.createElement("PRE");S.innerHTML=W;if(U){Q(S,U)}var T={langExtension:V,numberLines:U,sourceNode:S};d(T);return S.innerHTML}function b(ad){function Y(af){return document.getElementsByTagName(af)}var ac=[Y("pre"),Y("code"),Y("xmp")];var T=[];for(var aa=0;aa=0){var ah=ai.match(ab);var am;if(!ah&&(am=o(aj))&&"CODE"===am.tagName){ah=am.className.match(ab)}if(ah){ah=ah[1]}var al=false;for(var ak=aj.parentNode;ak;ak=ak.parentNode){if((ak.tagName==="pre"||ak.tagName==="code"||ak.tagName==="xmp")&&ak.className&&ak.className.indexOf("prettyprint")>=0){al=true;break}}if(!al){var af=aj.className.match(/\blinenums\b(?::(\d+))?/);af=af?af[1]&&af[1].length?+af[1]:true:false;if(af){Q(aj,af)}S={langExtension:ah,sourceNode:aj,numberLines:af};d(S)}}}if(X]*(?:>|$)/],[PR.PR_COMMENT,/^<\!--[\s\S]*?(?:-\->|$)/],[PR.PR_PUNCTUATION,/^(?:<[%?]|[%?]>)/],["lang-",/^<\?([\s\S]+?)(?:\?>|$)/],["lang-",/^<%([\s\S]+?)(?:%>|$)/],["lang-",/^]*>([\s\S]+?)<\/xmp\b[^>]*>/i],["lang-handlebars",/^]*type\s*=\s*['"]?text\/x-handlebars-template['"]?\b[^>]*>([\s\S]*?)(<\/script\b[^>]*>)/i],["lang-js",/^]*>([\s\S]*?)(<\/script\b[^>]*>)/i],["lang-css",/^]*>([\s\S]*?)(<\/style\b[^>]*>)/i],["lang-in.tag",/^(<\/?[a-z][^<>]*>)/i],[PR.PR_DECLARATION,/^{{[#^>/]?\s*[\w.][^}]*}}/],[PR.PR_DECLARATION,/^{{&?\s*[\w.][^}]*}}/],[PR.PR_DECLARATION,/^{{{>?\s*[\w.][^}]*}}}/],[PR.PR_COMMENT,/^{{![^}]*}}/]]),["handlebars","hbs"]);PR.registerLangHandler(PR.createSimpleLexer([[PR.PR_PLAIN,/^[ \t\r\n\f]+/,null," \t\r\n\f"]],[[PR.PR_STRING,/^\"(?:[^\n\r\f\\\"]|\\(?:\r\n?|\n|\f)|\\[\s\S])*\"/,null],[PR.PR_STRING,/^\'(?:[^\n\r\f\\\']|\\(?:\r\n?|\n|\f)|\\[\s\S])*\'/,null],["lang-css-str",/^url\(([^\)\"\']*)\)/i],[PR.PR_KEYWORD,/^(?:url|rgb|\!important|@import|@page|@media|@charset|inherit)(?=[^\-\w]|$)/i,null],["lang-css-kw",/^(-?(?:[_a-z]|(?:\\[0-9a-f]+ ?))(?:[_a-z0-9\-]|\\(?:\\[0-9a-f]+ ?))*)\s*:/i],[PR.PR_COMMENT,/^\/\*[^*]*\*+(?:[^\/*][^*]*\*+)*\//],[PR.PR_COMMENT,/^(?:)/],[PR.PR_LITERAL,/^(?:\d+|\d*\.\d+)(?:%|[a-z]+)?/i],[PR.PR_LITERAL,/^#(?:[0-9a-f]{3}){1,2}/i],[PR.PR_PLAIN,/^-?(?:[_a-z]|(?:\\[\da-f]+ ?))(?:[_a-z\d\-]|\\(?:\\[\da-f]+ ?))*/i],[PR.PR_PUNCTUATION,/^[^\s\w\'\"]+/]]),["css"]);PR.registerLangHandler(PR.createSimpleLexer([],[[PR.PR_KEYWORD,/^-?(?:[_a-z]|(?:\\[\da-f]+ ?))(?:[_a-z\d\-]|\\(?:\\[\da-f]+ ?))*/i]]),["css-kw"]);PR.registerLangHandler(PR.createSimpleLexer([],[[PR.PR_STRING,/^[^\)\"\']+/]]),["css-str"]); diff --git a/coverage/lcov-report/server/controllers/project.controller/createProject.js.html b/coverage/lcov-report/server/controllers/project.controller/createProject.js.html new file mode 100644 index 00000000..471acbd3 --- /dev/null +++ b/coverage/lcov-report/server/controllers/project.controller/createProject.js.html @@ -0,0 +1,370 @@ + + + + + + Code coverage report for server/controllers/project.controller/createProject.js + + + + + + + + +
+
+

All files / server/controllers/project.controller createProject.js

+
+ +
+ 94.12% + Statements + 32/34 +
+ + +
+ 90.91% + Branches + 10/11 +
+ + +
+ 90.91% + Functions + 10/11 +
+ + +
+ 94.12% + Lines + 32/34 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30 +31 +32 +33 +34 +35 +36 +37 +38 +39 +40 +41 +42 +43 +44 +45 +46 +47 +48 +49 +50 +51 +52 +53 +54 +55 +56 +57 +58 +59 +60 +61 +62 +63 +64 +65 +66 +67 +68 +69 +70 +71 +72 +73 +74 +75 +76 +77 +78 +79 +80 +81 +82 +83 +84 +85 +86 +87 +88 +89 +90 +91 +92 +93 +94 +95 +96 +97 +98  +  +  +  +4x +  +  +  +4x +  +  +2x +  +  +  +3x +  +  +  +3x +1x +1x +  +2x +  +  +  +  +  +4x +  +  +  +  +  +  +6x +  +  +5x +  +  +  +  +  +  +  +  +  +  +  +  +5x +3x +2x +2x +  +  +  +  +  +  +7x +1x +1x +1x +  +1x +  +  +  +6x +6x +  +5x +  +2x +  +2x +1x +  +1x +  +  +  +1x +1x +  +1x +  +  +  +  +4x +4x +  +  + 
import Project from '../../models/project';
+import { toModel, FileValidationError, ProjectValidationError } from '../../domain-objects/Project';
+ 
+export default function createProject(req, res) {
+  let projectValues = {
+    user: req.user._id
+  };
+ 
+  projectValues = Object.assign(projectValues, req.body);
+ 
+  function sendFailure() {
+    res.json({ success: false });
+  }
+ 
+  function populateUserData(newProject) {
+    return Project.populate(
+      newProject,
+      { path: 'user', select: 'username' },
+      (err, newProjectWithUser) => {
+        if (err) {
+          sendFailure();
+          return;
+        }
+        res.json(newProjectWithUser);
+      }
+    );
+  }
+ 
+ 
+  return Project.create(projectValues)
+    .then(populateUserData)
+    .catch(sendFailure);
+}
+ 
+// TODO: What happens if you don't supply any files?
+export function apiCreateProject(req, res) {
+  const params = Object.assign({ user: req.user._id }, req.body);
+ 
+  function sendValidationErrors(err, type, code = 422) {
+    res.status(code).json({
+      message: `${type} Validation Failed`,
+      detail: err.message,
+      errors: err.files,
+    });
+  }
+ 
+  // TODO: Error handling to match spec
+  function sendFailure(err) {
+    res.status(500).end();
+  }
+ 
+  function handleErrors(err) {
+    if (err instanceof FileValidationError) {
+      sendValidationErrors(err, 'File', err.code);
+    } else Eif (err instanceof ProjectValidationError) {
+      sendValidationErrors(err, 'Sketch', err.code);
+    } else {
+      sendFailure();
+    }
+  }
+ 
+  function checkUserHasPermission() {
+    if (req.user.username !== req.params.username) {
+      console.log('no permission');
+      const error = new ProjectValidationError(`'${req.user.username}' does not have permission to create for '${req.params.username}'`);
+      error.code = 401;
+ 
+      throw error;
+    }
+  }
+ 
+  try {
+    checkUserHasPermission();
+ 
+    const model = toModel(params);
+ 
+    return model.isSlugUnique()
+      .then(({ isUnique, conflictingIds }) => {
+        if (isUnique) {
+          return model.save()
+            .then((newProject) => {
+              res.status(201).json({ id: newProject.id });
+            });
+        }
+ 
+        const error = new ProjectValidationError(`Slug "${model.slug}" is not unique. Check ${conflictingIds.join(', ')}`);
+        error.code = 409;
+ 
+        throw error;
+      })
+      .then(checkUserHasPermission)
+      .catch(handleErrors);
+  } catch (err) {
+    handleErrors(err);
+    return Promise.reject(err);
+  }
+}
+ 
+ +
+
+ + + + + + + + + \ No newline at end of file diff --git a/coverage/lcov-report/server/controllers/project.controller/deleteProject.js.html b/coverage/lcov-report/server/controllers/project.controller/deleteProject.js.html new file mode 100644 index 00000000..67bbb9cc --- /dev/null +++ b/coverage/lcov-report/server/controllers/project.controller/deleteProject.js.html @@ -0,0 +1,250 @@ + + + + + + Code coverage report for server/controllers/project.controller/deleteProject.js + + + + + + + + +
+
+

All files / server/controllers/project.controller deleteProject.js

+
+ +
+ 68.18% + Statements + 15/22 +
+ + +
+ 38.46% + Branches + 5/13 +
+ + +
+ 75% + Functions + 6/8 +
+ + +
+ 68.18% + Lines + 15/22 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30 +31 +32 +33 +34 +35 +36 +37 +38 +39 +40 +41 +42 +43 +44 +45 +46 +47 +48 +49 +50 +51 +52 +53 +54 +55 +56 +57 +58  +  +  +  +  +1x +  +  +1x +  +  +  +  +  +  +  +  +  +  +  +  +  +  +2x +  +  +  +1x +  +  +  +3x +1x +1x +  +  +2x +1x +1x +  +  +1x +  +1x +1x +  +  +  +  +1x +  +  +  +3x +  +  +  + 
import isBefore from 'date-fns/is_before';
+import Project from '../../models/project';
+import { deleteObjectsFromS3, getObjectKey } from '../aws.controller';
+import createApplicationErrorClass from '../../utils/createApplicationErrorClass';
+ 
+const ProjectDeletionError = createApplicationErrorClass('ProjectDeletionError');
+ 
+function deleteFilesFromS3(files) {
+  deleteObjectsFromS3(files.filter((file) => {
+    if (file.url) {
+      if (!process.env.S3_DATE || (
+        process.env.S3_DATE &&
+        isBefore(new Date(process.env.S3_DATE), new Date(file.createdAt)))) {
+        return true;
+      }
+    }
+    return false;
+  })
+    .map(file => getObjectKey(file.url)));
+}
+ 
+export default function deleteProject(req, res) {
+  function sendFailure(error) {
+    res.status(error.code).json({ message: error.message });
+  }
+ 
+  function sendProjectNotFound() {
+    sendFailure(new ProjectDeletionError('Project with that id does not exist', { code: 404 }));
+  }
+ 
+  function handleProjectDeletion(project) {
+    if (project == null) {
+      sendProjectNotFound();
+      return;
+    }
+ 
+    if (!project.user.equals(req.user._id)) {
+      sendFailure(new ProjectDeletionError('Authenticated user does not match owner of project', { code: 403 }));
+      return;
+    }
+ 
+    deleteFilesFromS3(project.files);
+ 
+    project.remove((removeProjectError) => {
+      Iif (removeProjectError) {
+        sendProjectNotFound();
+        return;
+      }
+ 
+      res.status(200).end();
+    });
+  }
+ 
+  return Project.findById(req.params.project_id)
+    .then(handleProjectDeletion)
+    .catch(sendFailure);
+}
+ 
+ +
+
+ + + + + + + + + \ No newline at end of file diff --git a/coverage/lcov-report/server/controllers/project.controller/getProjectsForUser.js.html b/coverage/lcov-report/server/controllers/project.controller/getProjectsForUser.js.html new file mode 100644 index 00000000..70acc997 --- /dev/null +++ b/coverage/lcov-report/server/controllers/project.controller/getProjectsForUser.js.html @@ -0,0 +1,295 @@ + + + + + + Code coverage report for server/controllers/project.controller/getProjectsForUser.js + + + + + + + + +
+
+

All files / server/controllers/project.controller getProjectsForUser.js

+
+ +
+ 71.88% + Statements + 23/32 +
+ + +
+ 78.57% + Branches + 11/14 +
+ + +
+ 63.64% + Functions + 7/11 +
+ + +
+ 74.19% + Lines + 23/31 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30 +31 +32 +33 +34 +35 +36 +37 +38 +39 +40 +41 +42 +43 +44 +45 +46 +47 +48 +49 +50 +51 +52 +53 +54 +55 +56 +57 +58 +59 +60 +61 +62 +63 +64 +65 +66 +67 +68 +69 +70 +71 +72 +73  +  +  +  +  +1x +  +  +4x +4x +4x +2x +2x +  +  +2x +2x +2x +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +3x +2x +  +  +2x +1x +  +1x +  +  +  +  +  +1x +1x +  +  +  +3x +2x +  +  +  +  +  +2x +1x +  +1x +  +  +  +  +1x +1x +  + 
import Project from '../../models/project';
+import User from '../../models/user';
+import { toApi as toApiProjectObject } from '../../domain-objects/Project';
+import createApplicationErrorClass from '../../utils/createApplicationErrorClass';
+ 
+const UserNotFoundError = createApplicationErrorClass('UserNotFoundError');
+ 
+function getProjectsForUserName(username) {
+  return new Promise((resolve, reject) => {
+    User.findOne({ username }, (err, user) => {
+      if (err) {
+        reject(err);
+        return;
+      }
+ 
+      Eif (!user) {
+        reject(new UserNotFoundError());
+        return;
+      }
+ 
+      Project.find({ user: user._id })
+        .sort('-createdAt')
+        .select('name files id createdAt updatedAt')
+        .exec((innerErr, projects) => {
+          if (innerErr) {
+            reject(innerErr);
+            return;
+          }
+ 
+          resolve(projects);
+        });
+    });
+  });
+}
+ 
+export default function getProjectsForUser(req, res) {
+  if (req.params.username) {
+    return getProjectsForUserName(req.params.username)
+      .then(projects => res.json(projects))
+      .catch((err) => {
+        if (err instanceof UserNotFoundError) {
+          res.status(404).json({ message: 'User with that username does not exist.' });
+        } else {
+          res.status(500).json({ message: 'Error fetching projects' });
+        }
+      });
+  }
+ 
+  // could just move this to client side
+  res.status(200).json([]);
+  return Promise.resolve();
+}
+ 
+export function apiGetProjectsForUser(req, res) {
+  if (req.params.username) {
+    return getProjectsForUserName(req.params.username)
+      .then((projects) => {
+        const asApiObjects = projects.map(p => toApiProjectObject(p));
+        res.json({ sketches: asApiObjects });
+      })
+      .catch((err) => {
+        if (err instanceof UserNotFoundError) {
+          res.status(404).json({ message: 'User with that username does not exist.' });
+        } else {
+          res.status(500).json({ message: 'Error fetching projects' });
+        }
+      });
+  }
+ 
+  res.status(422).json({ message: 'Username not provided' });
+  return Promise.resolve();
+}
+ 
+ +
+
+ + + + + + + + + \ No newline at end of file diff --git a/coverage/lcov-report/server/controllers/project.controller/index.html b/coverage/lcov-report/server/controllers/project.controller/index.html new file mode 100644 index 00000000..2d6b4188 --- /dev/null +++ b/coverage/lcov-report/server/controllers/project.controller/index.html @@ -0,0 +1,140 @@ + + + + + + Code coverage report for server/controllers/project.controller + + + + + + + + +
+
+

All files server/controllers/project.controller

+
+ +
+ 79.55% + Statements + 70/88 +
+ + +
+ 68.42% + Branches + 26/38 +
+ + +
+ 76.67% + Functions + 23/30 +
+ + +
+ 80.46% + Lines + 70/87 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+
+
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
FileStatementsBranchesFunctionsLines
createProject.js +
+
94.12%32/3490.91%10/1190.91%10/1194.12%32/34
deleteProject.js +
+
68.18%15/2238.46%5/1375%6/868.18%15/22
getProjectsForUser.js +
+
71.88%23/3278.57%11/1463.64%7/1174.19%23/31
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/coverage/lcov-report/server/controllers/user.controller/apiKey.js.html b/coverage/lcov-report/server/controllers/user.controller/apiKey.js.html new file mode 100644 index 00000000..7add822f --- /dev/null +++ b/coverage/lcov-report/server/controllers/user.controller/apiKey.js.html @@ -0,0 +1,388 @@ + + + + + + Code coverage report for server/controllers/user.controller/apiKey.js + + + + + + + + +
+
+

All files / server/controllers/user.controller apiKey.js

+
+ +
+ 86% + Statements + 43/50 +
+ + +
+ 72.22% + Branches + 13/18 +
+ + +
+ 100% + Functions + 15/15 +
+ + +
+ 85.71% + Lines + 42/49 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30 +31 +32 +33 +34 +35 +36 +37 +38 +39 +40 +41 +42 +43 +44 +45 +46 +47 +48 +49 +50 +51 +52 +53 +54 +55 +56 +57 +58 +59 +60 +61 +62 +63 +64 +65 +66 +67 +68 +69 +70 +71 +72 +73 +74 +75 +76 +77 +78 +79 +80 +81 +82 +83 +84 +85 +86 +87 +88 +89 +90 +91 +92 +93 +94 +95 +96 +97 +98 +99 +100 +101 +102 +103 +104  +  +  +  +  +  +  +  +  +1x +1x +1x +  +  +1x +1x +  +  +  +  +  +3x +  +2x +2x +  +  +3x +3x +1x +1x +  +  +2x +1x +1x +  +  +1x +  +1x +  +1x +1x +  +  +  +  +1x +  +1x +1x +  +1x +  +  +  +  +1x +1x +  +  +  +  +  +  +3x +  +2x +2x +  +  +3x +3x +  +  +  +  +3x +1x +1x +  +  +2x +2x +1x +1x +  +  +1x +  +1x +1x +  +  +  +  +1x +1x +  +  +  +  + 
import crypto from 'crypto';
+ 
+import User from '../../models/user';
+ 
+/**
+ * Generates a unique token to be used as a Personal Access Token
+ * @returns Promise<String> A promise that resolves to the token, or an Error
+ */
+function generateApiKey() {
+  return new Promise((resolve, reject) => {
+    crypto.randomBytes(20, (err, buf) => {
+      Iif (err) {
+        reject(err);
+      }
+      const key = buf.toString('hex');
+      resolve(Buffer.from(key).toString('base64'));
+    });
+  });
+}
+ 
+export function createApiKey(req, res) {
+  return new Promise((resolve, reject) => {
+    function sendFailure(code, error) {
+      res.status(code).json({ error });
+      resolve();
+    }
+ 
+    User.findById(req.user.id, async (err, user) => {
+      if (!user) {
+        sendFailure(404, 'User not found');
+        return;
+      }
+ 
+      if (!req.body.label) {
+        sendFailure(400, 'Expected field \'label\' was not present in request body');
+        return;
+      }
+ 
+      const keyToBeHashed = await generateApiKey();
+ 
+      const addedApiKeyIndex = user.apiKeys.push({ label: req.body.label, hashedKey: keyToBeHashed });
+ 
+      user.save((saveErr) => {
+        Iif (saveErr) {
+          sendFailure(500, saveErr);
+          return;
+        }
+ 
+        const apiKeys = user.apiKeys
+          .map((apiKey, index) => {
+            const fields = apiKey.toObject();
+            const shouldIncludeToken = index === addedApiKeyIndex - 1;
+ 
+            return shouldIncludeToken ?
+              { ...fields, token: keyToBeHashed } :
+              fields;
+          });
+ 
+        res.json({ apiKeys });
+        resolve();
+      });
+    });
+  });
+}
+ 
+export function removeApiKey(req, res) {
+  return new Promise((resolve, reject) => {
+    function sendFailure(code, error) {
+      res.status(code).json({ error });
+      resolve();
+    }
+ 
+    User.findById(req.user.id, (err, user) => {
+      Iif (err) {
+        sendFailure(500, err);
+        return;
+      }
+ 
+      if (!user) {
+        sendFailure(404, 'User not found');
+        return;
+      }
+ 
+      const keyToDelete = user.apiKeys.find(key => key.id === req.params.keyId);
+      if (!keyToDelete) {
+        sendFailure(404, 'Key does not exist for user');
+        return;
+      }
+ 
+      user.apiKeys.pull({ _id: req.params.keyId });
+ 
+      user.save((saveErr) => {
+        Iif (saveErr) {
+          sendFailure(500, saveErr);
+          return;
+        }
+ 
+        res.status(200).json({ apiKeys: user.apiKeys });
+        resolve();
+      });
+    });
+  });
+}
+ 
+ +
+
+ + + + + + + + + \ No newline at end of file diff --git a/coverage/lcov-report/server/controllers/user.controller/index.html b/coverage/lcov-report/server/controllers/user.controller/index.html new file mode 100644 index 00000000..93a071cd --- /dev/null +++ b/coverage/lcov-report/server/controllers/user.controller/index.html @@ -0,0 +1,110 @@ + + + + + + Code coverage report for server/controllers/user.controller + + + + + + + + +
+
+

All files server/controllers/user.controller

+
+ +
+ 86% + Statements + 43/50 +
+ + +
+ 72.22% + Branches + 13/18 +
+ + +
+ 100% + Functions + 15/15 +
+ + +
+ 85.71% + Lines + 42/49 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+
+
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
FileStatementsBranchesFunctionsLines
apiKey.js +
+
86%43/5072.22%13/18100%15/1585.71%42/49
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/coverage/lcov-report/server/domain-objects/Project.js.html b/coverage/lcov-report/server/domain-objects/Project.js.html new file mode 100644 index 00000000..f1c03cf1 --- /dev/null +++ b/coverage/lcov-report/server/domain-objects/Project.js.html @@ -0,0 +1,478 @@ + + + + + + Code coverage report for server/domain-objects/Project.js + + + + + + + + +
+
+

All files / server/domain-objects Project.js

+
+ +
+ 97.78% + Statements + 44/45 +
+ + +
+ 87.5% + Branches + 14/16 +
+ + +
+ 87.5% + Functions + 7/8 +
+ + +
+ 97.73% + Lines + 43/44 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30 +31 +32 +33 +34 +35 +36 +37 +38 +39 +40 +41 +42 +43 +44 +45 +46 +47 +48 +49 +50 +51 +52 +53 +54 +55 +56 +57 +58 +59 +60 +61 +62 +63 +64 +65 +66 +67 +68 +69 +70 +71 +72 +73 +74 +75 +76 +77 +78 +79 +80 +81 +82 +83 +84 +85 +86 +87 +88 +89 +90 +91 +92 +93 +94 +95 +96 +97 +98 +99 +100 +101 +102 +103 +104 +105 +106 +107 +108 +109 +110 +111 +112 +113 +114 +115 +116 +117 +118 +119 +120 +121 +122 +123 +124 +125 +126 +127 +128 +129 +130 +131 +132 +133 +134  +  +  +  +  +  +  +3x +3x +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +40x +40x +  +40x +52x +52x +  +52x +23x +  +  +  +  +  +  +23x +  +  +  +23x +23x +23x +  +29x +  +  +  +  +  +29x +1x +28x +23x +  +5x +  +  +29x +  +  +  +  +52x +35x +  +  +  +40x +  +  +  +17x +  +  +  +  +  +17x +  +17x +4x +  +  +5x +  +4x +4x +  +4x +  +  +13x +  +  +  +14x +  +  +  +  +  +  +  +  +11x +11x +  +11x +8x +5x +  +  +8x +  +3x +  +  +6x +6x +  +6x +  + 
import isPlainObject from 'lodash/isPlainObject';
+import pick from 'lodash/pick';
+import Project from '../models/project';
+import createId from '../utils/createId';
+import createApplicationErrorClass from '../utils/createApplicationErrorClass';
+import createDefaultFiles from './createDefaultFiles';
+ 
+export const FileValidationError = createApplicationErrorClass('FileValidationError');
+export const ProjectValidationError = createApplicationErrorClass('ProjectValidationError');
+ 
+/**
+ * This converts between a mongoose Project model
+ * and the public API Project object properties
+ *
+ */
+export function toApi(model) {
+  return {
+    id: model.id,
+    name: model.name,
+  };
+}
+ 
+/**
+ * Transforms a tree of files matching the APIs DirectoryContents
+ * format into the data structure stored in mongodb
+ *
+ * - flattens the tree into an array of file/folders
+ * - each file/folder gets a generated BSON-ID
+ * - each folder has a `children` array containing the IDs of it's children
+ */
+function transformFilesInner(tree = {}, parentNode) {
+  const files = [];
+  const errors = [];
+ 
+  Object.entries(tree).forEach(([name, params]) => {
+    const id = createId();
+    const isFolder = params.files != null;
+ 
+    if (isFolder) {
+      const folder = {
+        _id: id,
+        name,
+        fileType: 'folder',
+        children: [] // Initialise an empty folder
+      };
+ 
+      files.push(folder);
+ 
+      // The recursion will return a list of child files/folders
+      // It will also push the child's id into `folder.children`
+      const subFolder = transformFilesInner(params.files, folder);
+      files.push(...subFolder.files);
+      errors.push(...subFolder.errors);
+    } else {
+      const file = {
+        _id: id,
+        name,
+        fileType: 'file'
+      };
+ 
+      if (typeof params.url === 'string') {
+        file.url = params.url;
+      } else if (typeof params.content === 'string') {
+        file.content = params.content;
+      } else {
+        errors.push({ name, message: 'missing \'url\' or \'content\'' });
+      }
+ 
+      files.push(file);
+    }
+ 
+    // Push this child's ID onto it's parent's list
+    // of children
+    if (parentNode != null) {
+      parentNode.children.push(id);
+    }
+  });
+ 
+  return { files, errors };
+}
+ 
+export function transformFiles(tree = {}) {
+  const withRoot = {
+    root: {
+      files: tree
+    }
+  };
+ 
+  const { files, errors } = transformFilesInner(withRoot);
+ 
+  if (errors.length > 0) {
+    const message = `${errors.length} files failed validation. See error.files for individual errors.
+    
+    Errors:
+      ${errors.map(e => `* ${e.name}: ${e.message}`).join('\n')}
+`;
+    const error = new FileValidationError(message);
+    error.files = errors;
+ 
+    throw error;
+  }
+ 
+  return files;
+}
+ 
+export function containsRootHtmlFile(tree) {
+  return Object.keys(tree).find(name => /\.html$/.test(name)) != null;
+}
+ 
+/**
+ * This converts between the public API's Project object
+ * properties and a mongoose Project model
+ *
+ */
+export function toModel(object) {
+  let files = [];
+  let tree = object.files;
+ 
+  if (isPlainObject(tree)) {
+    if (!containsRootHtmlFile(tree)) {
+      tree = Object.assign(createDefaultFiles(), tree);
+    }
+ 
+    files = transformFiles(tree);
+  } else {
+    throw new FileValidationError('\'files\' must be an object');
+  }
+ 
+  const projectValues = pick(object, ['user', 'name', 'slug']);
+  projectValues.files = files;
+ 
+  return new Project(projectValues);
+}
+ 
+ +
+
+ + + + + + + + + \ No newline at end of file diff --git a/coverage/lcov-report/server/domain-objects/createDefaultFiles.js.html b/coverage/lcov-report/server/domain-objects/createDefaultFiles.js.html new file mode 100644 index 00000000..05adfd85 --- /dev/null +++ b/coverage/lcov-report/server/domain-objects/createDefaultFiles.js.html @@ -0,0 +1,223 @@ + + + + + + Code coverage report for server/domain-objects/createDefaultFiles.js + + + + + + + + +
+
+

All files / server/domain-objects createDefaultFiles.js

+
+ +
+ 100% + Statements + 4/4 +
+ + +
+ 100% + Branches + 0/0 +
+ + +
+ 100% + Functions + 1/1 +
+ + +
+ 100% + Lines + 4/4 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30 +31 +32 +33 +34 +35 +36 +37 +38 +39 +40 +41 +42 +43 +44 +45 +46 +47 +48 +493x +  +  +  +  +  +  +  +  +3x +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +3x +  +  +  +  +  +  +  +  +  +5x +  +  +  +  +  +  +  +  +  +  +  + 
const defaultSketch = `function setup() {
+  createCanvas(400, 400);
+}
+ 
+function draw() {
+  background(220);
+}`;
+ 
+const defaultHTML =
+  `<!DOCTYPE html>
+<html>
+  <head>
+    <script src="https://cdnjs.cloudflare.com/ajax/libs/p5.js/0.8.0/p5.js"></script>
+    <script src="https://cdnjs.cloudflare.com/ajax/libs/p5.js/0.8.0/addons/p5.dom.min.js"></script>
+    <script src="https://cdnjs.cloudflare.com/ajax/libs/p5.js/0.8.0/addons/p5.sound.min.js"></script>
+    <link rel="stylesheet" type="text/css" href="style.css">
+    <meta charset="utf-8" />
+ 
+  </head>
+  <body>
+    <script src="sketch.js"></script>
+  </body>
+</html>
+`;
+ 
+const defaultCSS =
+  `html, body {
+  margin: 0;
+  padding: 0;
+}
+canvas {
+  display: block;
+}
+`;
+ 
+export default function createDefaultFiles() {
+  return {
+    'index.html': {
+      content: defaultHTML
+    },
+    'style.css': {
+      content: defaultCSS
+    },
+    'sketch.js': {
+      content: defaultSketch
+    }
+  };
+}
+ 
+ +
+
+ + + + + + + + + \ No newline at end of file diff --git a/coverage/lcov-report/server/domain-objects/index.html b/coverage/lcov-report/server/domain-objects/index.html new file mode 100644 index 00000000..e2779fe9 --- /dev/null +++ b/coverage/lcov-report/server/domain-objects/index.html @@ -0,0 +1,125 @@ + + + + + + Code coverage report for server/domain-objects + + + + + + + + +
+
+

All files server/domain-objects

+
+ +
+ 97.96% + Statements + 48/49 +
+ + +
+ 87.5% + Branches + 14/16 +
+ + +
+ 88.89% + Functions + 8/9 +
+ + +
+ 97.92% + Lines + 47/48 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+
+
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
FileStatementsBranchesFunctionsLines
Project.js +
+
97.78%44/4587.5%14/1687.5%7/897.73%43/44
createDefaultFiles.js +
+
100%4/4100%0/0100%1/1100%4/4
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/coverage/lcov-report/server/models/index.html b/coverage/lcov-report/server/models/index.html new file mode 100644 index 00000000..9a2ec3e1 --- /dev/null +++ b/coverage/lcov-report/server/models/index.html @@ -0,0 +1,125 @@ + + + + + + Code coverage report for server/models + + + + + + + + +
+
+

All files server/models

+
+ +
+ 37.65% + Statements + 32/85 +
+ + +
+ 3.57% + Branches + 1/28 +
+ + +
+ 20% + Functions + 4/20 +
+ + +
+ 41.56% + Lines + 32/77 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+
+
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
FileStatementsBranchesFunctionsLines
project.js +
+
51.85%14/2712.5%1/840%2/551.85%14/27
user.js +
+
31.03%18/580%0/2013.33%2/1536%18/50
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/coverage/lcov-report/server/models/project.js.html b/coverage/lcov-report/server/models/project.js.html new file mode 100644 index 00000000..e43c2ffe --- /dev/null +++ b/coverage/lcov-report/server/models/project.js.html @@ -0,0 +1,352 @@ + + + + + + Code coverage report for server/models/project.js + + + + + + + + +
+
+

All files / server/models project.js

+
+ +
+ 51.85% + Statements + 14/27 +
+ + +
+ 12.5% + Branches + 1/8 +
+ + +
+ 40% + Functions + 2/5 +
+ + +
+ 51.85% + Lines + 14/27 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30 +31 +32 +33 +34 +35 +36 +37 +38 +39 +40 +41 +42 +43 +44 +45 +46 +47 +48 +49 +50 +51 +52 +53 +54 +55 +56 +57 +58 +59 +60 +61 +62 +63 +64 +65 +66 +67 +68 +69 +70 +71 +72 +73 +74 +75 +76 +77 +78 +79 +80 +81 +82 +83 +84 +85 +86 +87 +88 +89 +90 +91 +92  +  +  +  +  +  +  +5x +  +5x +  +  +  +  +  +  +  +  +  +  +  +5x +  +  +  +5x +  +  +  +5x +  +  +  +  +  +  +  +  +  +  +  +5x +3x +  +  +5x +  +  +  +5x +5x +  +5x +5x +  +  +5x +  +  +  +  +  +5x +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  + 
import mongoose from 'mongoose';
+import shortid from 'shortid';
+import slugify from 'slugify';
+ 
+// Register User model as it's referenced by Project
+import './user';
+ 
+const { Schema } = mongoose;
+ 
+const fileSchema = new Schema(
+  {
+    name: { type: String, default: 'sketch.js' },
+    content: { type: String, default: '' },
+    url: { type: String },
+    children: { type: [String], default: [] },
+    fileType: { type: String, default: 'file' },
+    isSelectedFile: { type: Boolean }
+  },
+  { timestamps: true, _id: true, usePushEach: true }
+);
+ 
+fileSchema.virtual('id').get(function getFileId() {
+  return this._id.toHexString();
+});
+ 
+fileSchema.set('toJSON', {
+  virtuals: true
+});
+ 
+const projectSchema = new Schema(
+  {
+    name: { type: String, default: "Hello p5.js, it's the server" },
+    user: { type: Schema.Types.ObjectId, ref: 'User' },
+    serveSecure: { type: Boolean, default: false },
+    files: { type: [fileSchema] },
+    _id: { type: String, default: shortid.generate },
+    slug: { type: String }
+  },
+  { timestamps: true, usePushEach: true }
+);
+ 
+projectSchema.virtual('id').get(function getProjectId() {
+  return this._id;
+});
+ 
+projectSchema.set('toJSON', {
+  virtuals: true
+});
+ 
+projectSchema.pre('save', function generateSlug(next) {
+  const project = this;
+ 
+  Eif (!project.slug) {
+    project.slug = slugify(project.name, '_');
+  }
+ 
+  return next();
+});
+ 
+/**
+ * Check if slug is unique for this user's projects
+ */
+projectSchema.methods.isSlugUnique = async function isSlugUnique(cb) {
+  const project = this;
+  const hasCallback = typeof cb === 'function';
+ 
+  try {
+    const docsWithSlug = await project.model('Project')
+      .find({ user: project.user, slug: project.slug }, '_id')
+      .exec();
+ 
+    const result = {
+      isUnique: docsWithSlug.length === 0,
+      conflictingIds: docsWithSlug.map(d => d._id) || []
+    };
+ 
+    if (hasCallback) {
+      cb(null, result);
+    }
+ 
+    return result;
+  } catch (err) {
+    if (hasCallback) {
+      cb(err, null);
+    }
+ 
+    throw err;
+  }
+};
+ 
+export default mongoose.model('Project', projectSchema);
+ 
+ +
+
+ + + + + + + + + \ No newline at end of file diff --git a/coverage/lcov-report/server/models/user.js.html b/coverage/lcov-report/server/models/user.js.html new file mode 100644 index 00000000..cd9c6605 --- /dev/null +++ b/coverage/lcov-report/server/models/user.js.html @@ -0,0 +1,550 @@ + + + + + + Code coverage report for server/models/user.js + + + + + + + + +
+
+

All files / server/models user.js

+
+ +
+ 31.03% + Statements + 18/58 +
+ + +
+ 0% + Branches + 0/20 +
+ + +
+ 13.33% + Functions + 2/15 +
+ + +
+ 36% + Lines + 18/50 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30 +31 +32 +33 +34 +35 +36 +37 +38 +39 +40 +41 +42 +43 +44 +45 +46 +47 +48 +49 +50 +51 +52 +53 +54 +55 +56 +57 +58 +59 +60 +61 +62 +63 +64 +65 +66 +67 +68 +69 +70 +71 +72 +73 +74 +75 +76 +77 +78 +79 +80 +81 +82 +83 +84 +85 +86 +87 +88 +89 +90 +91 +92 +93 +94 +95 +96 +97 +98 +99 +100 +101 +102 +103 +104 +105 +106 +107 +108 +109 +110 +111 +112 +113 +114 +115 +116 +117 +118 +119 +120 +121 +122 +123 +124 +125 +126 +127 +128 +129 +130 +131 +132 +133 +134 +135 +136 +137 +138 +139 +140 +141 +142 +143 +144 +145 +146 +147 +148 +149 +150 +151 +152 +153 +154 +155 +156 +157 +158  +  +6x +  +6x +  +  +  +  +  +6x +  +6x +  +  +  +  +  +6x +3x +  +  +  +  +  +  +  +  +1x +  +  +  +  +6x +  +  +  +6x +  +  +  +  +6x +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +6x +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +6x +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +  +6x +  +  +  +6x +  +  +  +  +  +  +6x +  +  +  +  +  +  +  +  +  +6x +  +  +  +  +  +  +  +  +  +  +6x +  +  +  +  +  +  +  +  +  +  +6x +  +  + 
import mongoose from 'mongoose';
+ 
+const bcrypt = require('bcrypt-nodejs');
+ 
+const EmailConfirmationStates = {
+  Verified: 'verified',
+  Sent: 'sent',
+  Resent: 'resent',
+};
+ 
+const { Schema } = mongoose;
+ 
+const apiKeySchema = new Schema({
+  label: { type: String, default: 'API Key' },
+  lastUsedAt: { type: Date },
+  hashedKey: { type: String, required: true },
+}, { timestamps: true, _id: true });
+ 
+apiKeySchema.virtual('id').get(function getApiKeyId() {
+  return this._id.toHexString();
+});
+ 
+/**
+ * When serialising an APIKey instance, the `hashedKey` field
+ * should never be exposed to the client. So we only return
+ * a safe list of fields when toObject and toJSON are called.
+*/
+function apiKeyMetadata(doc, ret, options) {
+  return {
+    id: doc.id, label: doc.label, lastUsedAt: doc.lastUsedAt, createdAt: doc.createdAt
+  };
+}
+ 
+apiKeySchema.set('toObject', {
+  transform: apiKeyMetadata
+});
+ 
+apiKeySchema.set('toJSON', {
+  virtuals: true,
+  transform: apiKeyMetadata
+});
+ 
+const userSchema = new Schema({
+  name: { type: String, default: '' },
+  username: { type: String, required: true, unique: true },
+  password: { type: String },
+  resetPasswordToken: String,
+  resetPasswordExpires: Date,
+  verified: { type: String },
+  verifiedToken: String,
+  verifiedTokenExpires: Date,
+  github: { type: String },
+  email: { type: String, unique: true },
+  tokens: Array,
+  apiKeys: { type: [apiKeySchema] },
+  preferences: {
+    fontSize: { type: Number, default: 18 },
+    lineNumbers: { type: Boolean, default: true },
+    indentationAmount: { type: Number, default: 2 },
+    isTabIndent: { type: Boolean, default: false },
+    autosave: { type: Boolean, default: true },
+    linewrap: { type: Boolean, default: true },
+    lintWarning: { type: Boolean, default: false },
+    textOutput: { type: Boolean, default: false },
+    gridOutput: { type: Boolean, default: false },
+    soundOutput: { type: Boolean, default: false },
+    theme: { type: String, default: 'light' },
+    autorefresh: { type: Boolean, default: false }
+  },
+  totalSize: { type: Number, default: 0 }
+}, { timestamps: true, usePushEach: true });
+ 
+/**
+ * Password hash middleware.
+ */
+userSchema.pre('save', function checkPassword(next) { // eslint-disable-line consistent-return
+  const user = this;
+  if (!user.isModified('password')) { return next(); }
+  bcrypt.genSalt(10, (err, salt) => { // eslint-disable-line consistent-return
+    if (err) { return next(err); }
+    bcrypt.hash(user.password, salt, null, (innerErr, hash) => {
+      if (innerErr) { return next(innerErr); }
+      user.password = hash;
+      return next();
+    });
+  });
+});
+ 
+/**
+ * API keys hash middleware
+ */
+userSchema.pre('save', function checkApiKey(next) { // eslint-disable-line consistent-return
+  const user = this;
+  if (!user.isModified('apiKeys')) { return next(); }
+  let hasNew = false;
+  user.apiKeys.forEach((k) => {
+    if (k.isNew) {
+      hasNew = true;
+      bcrypt.genSalt(10, (err, salt) => { // eslint-disable-line consistent-return
+        if (err) { return next(err); }
+        bcrypt.hash(k.hashedKey, salt, null, (innerErr, hash) => {
+          if (innerErr) { return next(innerErr); }
+          k.hashedKey = hash;
+          return next();
+        });
+      });
+    }
+  });
+  if (!hasNew) return next();
+});
+ 
+userSchema.virtual('id').get(function idToString() {
+  return this._id.toHexString();
+});
+ 
+userSchema.set('toJSON', {
+  virtuals: true
+});
+ 
+/**
+ * Helper method for validating user's password.
+ */
+userSchema.methods.comparePassword = function comparePassword(candidatePassword, cb) {
+// userSchema.methods.comparePassword = (candidatePassword, cb) => {
+  bcrypt.compare(candidatePassword, this.password, (err, isMatch) => {
+    cb(err, isMatch);
+  });
+};
+ 
+/**
+ * Helper method for validating a user's api key
+ */
+userSchema.methods.findMatchingKey = function findMatchingKey(candidateKey, cb) {
+  let foundOne = false;
+  this.apiKeys.forEach((k) => {
+    if (bcrypt.compareSync(candidateKey, k.hashedKey)) {
+      foundOne = true;
+      cb(null, true, k);
+    }
+  });
+  if (!foundOne) cb('Matching API key not found !', false, null);
+};
+ 
+userSchema.statics.findByMailOrName = function findByMailOrName(email) {
+  const query = {
+    $or: [{
+      email,
+    }, {
+      username: email,
+    }],
+  };
+  return this.findOne(query).exec();
+};
+ 
+userSchema.statics.EmailConfirmation = EmailConfirmationStates;
+ 
+export default mongoose.model('User', userSchema);
+ 
+ +
+
+ + + + + + + + + \ No newline at end of file diff --git a/coverage/lcov-report/server/utils/createApplicationErrorClass.js.html b/coverage/lcov-report/server/utils/createApplicationErrorClass.js.html new file mode 100644 index 00000000..d8d5f639 --- /dev/null +++ b/coverage/lcov-report/server/utils/createApplicationErrorClass.js.html @@ -0,0 +1,178 @@ + + + + + + Code coverage report for server/utils/createApplicationErrorClass.js + + + + + + + + +
+
+

All files / server/utils createApplicationErrorClass.js

+
+ +
+ 100% + Statements + 9/9 +
+ + +
+ 66.67% + Branches + 2/3 +
+ + +
+ 100% + Functions + 3/3 +
+ + +
+ 100% + Lines + 9/9 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 +16 +17 +18 +19 +20 +21 +22 +23 +24 +25 +26 +27 +28 +29 +30 +31 +32 +33 +34  +  +  +  +  +  +13x +13x +13x +  +13x +13x +13x +  +  +  +  +  +  +  +  +  +  +  +  +8x +  +13x +  +13x +  +  +  + 
/**
+ * This is the base class for custom errors in
+ * the application.
+ */
+export class ApplicationError extends Error {
+  constructor(message, extra = {}) {
+    super();
+    Eif (Error.captureStackTrace) {
+      Error.captureStackTrace(this, this.constructor);
+    }
+    this.name = 'ApplicationError';
+    this.message = message;
+    this.code = extra.code;
+  }
+}
+ 
+/**
+ * Create a new custom error class e.g.
+ *   const UserNotFoundError = createApplicationErrorClass('UserNotFoundError');
+ *
+ * // Later
+ *  throw new UserNotFoundError(`user ${user.name} not found`);
+ *
+ */
+export default function createApplicationErrorClass(name) {
+  return class extends ApplicationError {
+    constructor(...params) {
+      super(...params);
+ 
+      this.name = name;
+    }
+  };
+}
+ 
+ +
+
+ + + + + + + + + \ No newline at end of file diff --git a/coverage/lcov-report/server/utils/createId.js.html b/coverage/lcov-report/server/utils/createId.js.html new file mode 100644 index 00000000..4064969a --- /dev/null +++ b/coverage/lcov-report/server/utils/createId.js.html @@ -0,0 +1,103 @@ + + + + + + Code coverage report for server/utils/createId.js + + + + + + + + +
+
+

All files / server/utils createId.js

+
+ +
+ 100% + Statements + 1/1 +
+ + +
+ 100% + Branches + 0/0 +
+ + +
+ 100% + Functions + 1/1 +
+ + +
+ 100% + Lines + 1/1 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+
+
+

+
1 +2 +3 +4 +5 +6 +7 +8 +9  +  +  +  +  +  +10x +  + 
import objectID from 'bson-objectid';
+ 
+/**
+ * Creates a mongo ID
+ */
+export default function createId() {
+  return objectID().toHexString();
+}
+ 
+ +
+
+ + + + + + + + + \ No newline at end of file diff --git a/coverage/lcov-report/server/utils/index.html b/coverage/lcov-report/server/utils/index.html new file mode 100644 index 00000000..98afcd90 --- /dev/null +++ b/coverage/lcov-report/server/utils/index.html @@ -0,0 +1,125 @@ + + + + + + Code coverage report for server/utils + + + + + + + + +
+
+

All files server/utils

+
+ +
+ 100% + Statements + 10/10 +
+ + +
+ 66.67% + Branches + 2/3 +
+ + +
+ 100% + Functions + 4/4 +
+ + +
+ 100% + Lines + 10/10 +
+ + +
+

+ Press n or j to go to the next uncovered block, b, p or k for the previous block. +

+
+
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
FileStatementsBranchesFunctionsLines
createApplicationErrorClass.js +
+
100%9/966.67%2/3100%3/3100%9/9
createId.js +
+
100%1/1100%0/0100%1/1100%1/1
+
+
+
+ + + + + + + + + \ No newline at end of file diff --git a/coverage/lcov-report/sort-arrow-sprite.png b/coverage/lcov-report/sort-arrow-sprite.png new file mode 100644 index 0000000000000000000000000000000000000000..03f704a609c6fd0dbfdac63466a7d7c958b5cbf3 GIT binary patch literal 209 zcmeAS@N?(olHy`uVBq!ia0vp^>_9Bd!3HEZxJ@+%Qj#UE5hcO-X(i=}MX3yqDfvmM z3ZA)%>8U}fi7AzZCsS>Jii$m5978H@?Fn+^JD|Y9yzj{W`447Gxa{7*dM7nnnD-Lb z6^}Hx2)'; + } + } + return cols; + } + // attaches a data attribute to every tr element with an object + // of data values keyed by column name + function loadRowData(tableRow) { + var tableCols = tableRow.querySelectorAll('td'), + colNode, + col, + data = {}, + i, + val; + for (i = 0; i < tableCols.length; i += 1) { + colNode = tableCols[i]; + col = cols[i]; + val = colNode.getAttribute('data-value'); + if (col.type === 'number') { + val = Number(val); + } + data[col.key] = val; + } + return data; + } + // loads all row data + function loadData() { + var rows = getTableBody().querySelectorAll('tr'), + i; + + for (i = 0; i < rows.length; i += 1) { + rows[i].data = loadRowData(rows[i]); + } + } + // sorts the table using the data for the ith column + function sortByIndex(index, desc) { + var key = cols[index].key, + sorter = function(a, b) { + a = a.data[key]; + b = b.data[key]; + return a < b ? -1 : a > b ? 1 : 0; + }, + finalSorter = sorter, + tableBody = document.querySelector('.coverage-summary tbody'), + rowNodes = tableBody.querySelectorAll('tr'), + rows = [], + i; + + if (desc) { + finalSorter = function(a, b) { + return -1 * sorter(a, b); + }; + } + + for (i = 0; i < rowNodes.length; i += 1) { + rows.push(rowNodes[i]); + tableBody.removeChild(rowNodes[i]); + } + + rows.sort(finalSorter); + + for (i = 0; i < rows.length; i += 1) { + tableBody.appendChild(rows[i]); + } + } + // removes sort indicators for current column being sorted + function removeSortIndicators() { + var col = getNthColumn(currentSort.index), + cls = col.className; + + cls = cls.replace(/ sorted$/, '').replace(/ sorted-desc$/, ''); + col.className = cls; + } + // adds sort indicators for current column being sorted + function addSortIndicators() { + getNthColumn(currentSort.index).className += currentSort.desc + ? ' sorted-desc' + : ' sorted'; + } + // adds event listeners for all sorter widgets + function enableUI() { + var i, + el, + ithSorter = function ithSorter(i) { + var col = cols[i]; + + return function() { + var desc = col.defaultDescSort; + + if (currentSort.index === i) { + desc = !currentSort.desc; + } + sortByIndex(i, desc); + removeSortIndicators(); + currentSort.index = i; + currentSort.desc = desc; + addSortIndicators(); + }; + }; + for (i = 0; i < cols.length; i += 1) { + if (cols[i].sortable) { + // add the click event handler on the th so users + // dont have to click on those tiny arrows + el = getNthColumn(i).querySelector('.sorter').parentElement; + if (el.addEventListener) { + el.addEventListener('click', ithSorter(i)); + } else { + el.attachEvent('onclick', ithSorter(i)); + } + } + } + } + // adds sorting functionality to the UI + return function() { + if (!getTable()) { + return; + } + cols = loadColumns(); + loadData(); + addSortIndicators(); + enableUI(); + }; +})(); + +window.addEventListener('load', addSorting); diff --git a/coverage/lcov.info b/coverage/lcov.info new file mode 100644 index 00000000..3e3f947e --- /dev/null +++ b/coverage/lcov.info @@ -0,0 +1,2376 @@ +TN: +SF:/home/lalis/git/p5.js-web-editor/client/constants.js +FNF:0 +FNH:0 +DA:3,2 +DA:4,2 +DA:6,2 +DA:7,2 +DA:9,2 +DA:10,2 +DA:12,2 +DA:13,2 +DA:14,2 +DA:15,2 +DA:17,2 +DA:18,2 +DA:19,2 +DA:21,2 +DA:23,2 +DA:24,2 +DA:26,2 +DA:27,2 +DA:29,2 +DA:30,2 +DA:31,2 +DA:32,2 +DA:33,2 +DA:34,2 +DA:36,2 +DA:37,2 +DA:39,2 +DA:40,2 +DA:41,2 +DA:43,2 +DA:44,2 +DA:45,2 +DA:47,2 +DA:49,2 +DA:50,2 +DA:51,2 +DA:52,2 +DA:53,2 +DA:55,2 +DA:56,2 +DA:58,2 +DA:59,2 +DA:60,2 +DA:61,2 +DA:63,2 +DA:64,2 +DA:66,2 +DA:67,2 +DA:69,2 +DA:70,2 +DA:71,2 +DA:72,2 +DA:73,2 +DA:74,2 +DA:75,2 +DA:77,2 +DA:78,2 +DA:79,2 +DA:80,2 +DA:81,2 +DA:82,2 +DA:83,2 +DA:84,2 +DA:86,2 +DA:87,2 +DA:88,2 +DA:89,2 +DA:90,2 +DA:91,2 +DA:92,2 +DA:93,2 +DA:94,2 +DA:95,2 +DA:97,2 +DA:98,2 +DA:99,2 +DA:100,2 +DA:102,2 +DA:103,2 +DA:105,2 +DA:106,2 +DA:107,2 +DA:109,2 +DA:110,2 +DA:111,2 +DA:112,2 +DA:115,2 +DA:117,2 +DA:118,2 +DA:120,2 +DA:121,2 +DA:122,2 +DA:123,2 +DA:124,2 +DA:126,2 +DA:127,2 +DA:129,2 +DA:130,2 +DA:131,2 +DA:132,2 +DA:134,2 +DA:135,2 +DA:136,2 +DA:137,2 +DA:138,2 +DA:140,2 +DA:141,2 +DA:143,2 +DA:144,2 +LF:109 +LH:109 +BRF:0 +BRH:0 +end_of_record +TN: +SF:/home/lalis/git/p5.js-web-editor/client/persistState.js +FN:8,(anonymous_0) +FN:16,(anonymous_1) +FN:25,(anonymous_2) +FNF:3 +FNH:0 +FNDA:0,(anonymous_0) +FNDA:0,(anonymous_1) +FNDA:0,(anonymous_2) +DA:5,2 +DA:6,2 +DA:8,2 +DA:9,0 +DA:10,0 +DA:12,0 +DA:16,2 +DA:17,0 +DA:18,0 +DA:20,0 +DA:21,0 +DA:25,2 +DA:26,0 +LF:13 +LH:5 +BRF:0 +BRH:0 +end_of_record +TN: +SF:/home/lalis/git/p5.js-web-editor/client/__test__/mocks/fileMock.js +FNF:0 +FNH:0 +DA:1,2 +LF:1 +LH:1 +BRF:0 +BRH:0 +end_of_record +TN: +SF:/home/lalis/git/p5.js-web-editor/client/components/Nav.jsx +FN:23,(anonymous_0) +FN:63,(anonymous_1) +FN:67,(anonymous_2) +FN:72,(anonymous_3) +FN:78,(anonymous_4) +FN:84,(anonymous_5) +FN:95,(anonymous_6) +FN:109,(anonymous_7) +FN:118,(anonymous_8) +FN:123,(anonymous_9) +FN:128,(anonymous_10) +FN:133,(anonymous_11) +FN:138,(anonymous_12) +FN:143,(anonymous_13) +FN:148,(anonymous_14) +FN:153,(anonymous_15) +FN:158,(anonymous_16) +FN:163,(anonymous_17) +FN:168,(anonymous_18) +FN:173,(anonymous_19) +FN:179,(anonymous_20) +FN:184,(anonymous_21) +FN:190,(anonymous_22) +FN:196,(anonymous_23) +FN:208,(anonymous_24) +FN:212,(anonymous_25) +FN:217,(anonymous_26) +FN:224,(anonymous_27) +FN:228,(anonymous_28) +FN:246,(anonymous_29) +FN:257,(anonymous_30) +FN:359,(anonymous_31) +FN:371,(anonymous_32) +FN:419,(anonymous_33) +FN:494,(anonymous_34) +FN:540,(anonymous_35) +FN:558,(anonymous_36) +FN:571,(anonymous_37) +FN:638,(anonymous_38) +FN:651,(anonymous_39) +FN:661,(anonymous_40) +FN:686,(anonymous_41) +FN:764,mapStateToProps +FN:769,(anonymous_43) +FNF:44 +FNH:7 +FNDA:2,(anonymous_0) +FNDA:2,(anonymous_1) +FNDA:0,(anonymous_2) +FNDA:0,(anonymous_3) +FNDA:0,(anonymous_4) +FNDA:0,(anonymous_5) +FNDA:0,(anonymous_6) +FNDA:0,(anonymous_7) +FNDA:0,(anonymous_8) +FNDA:0,(anonymous_9) +FNDA:0,(anonymous_10) +FNDA:0,(anonymous_11) +FNDA:0,(anonymous_12) +FNDA:0,(anonymous_13) +FNDA:0,(anonymous_14) +FNDA:0,(anonymous_15) +FNDA:0,(anonymous_16) +FNDA:0,(anonymous_17) +FNDA:0,(anonymous_18) +FNDA:0,(anonymous_19) +FNDA:0,(anonymous_20) +FNDA:0,(anonymous_21) +FNDA:0,(anonymous_22) +FNDA:0,(anonymous_23) +FNDA:0,(anonymous_24) +FNDA:0,(anonymous_25) +FNDA:0,(anonymous_26) +FNDA:0,(anonymous_27) +FNDA:0,(anonymous_28) +FNDA:2,(anonymous_29) +FNDA:0,(anonymous_30) +FNDA:0,(anonymous_31) +FNDA:0,(anonymous_32) +FNDA:0,(anonymous_33) +FNDA:0,(anonymous_34) +FNDA:0,(anonymous_35) +FNDA:0,(anonymous_36) +FNDA:0,(anonymous_37) +FNDA:2,(anonymous_38) +FNDA:2,(anonymous_39) +FNDA:2,(anonymous_40) +FNDA:1,(anonymous_41) +FNDA:0,mapStateToProps +FNDA:0,(anonymous_43) +DA:17,1 +DA:18,1 +DA:20,1 +DA:24,2 +DA:25,2 +DA:28,2 +DA:29,2 +DA:30,2 +DA:31,2 +DA:32,2 +DA:33,2 +DA:34,2 +DA:35,2 +DA:36,2 +DA:37,2 +DA:38,2 +DA:39,2 +DA:40,2 +DA:41,2 +DA:42,2 +DA:43,2 +DA:44,2 +DA:45,2 +DA:46,2 +DA:47,2 +DA:48,2 +DA:49,2 +DA:50,2 +DA:51,2 +DA:52,2 +DA:53,2 +DA:54,2 +DA:55,2 +DA:56,2 +DA:57,2 +DA:58,2 +DA:59,2 +DA:60,2 +DA:64,2 +DA:65,2 +DA:68,0 +DA:69,0 +DA:73,0 +DA:79,0 +DA:80,0 +DA:85,0 +DA:86,0 +DA:88,0 +DA:89,0 +DA:92,0 +DA:96,0 +DA:97,0 +DA:98,0 +DA:99,0 +DA:100,0 +DA:101,0 +DA:102,0 +DA:103,0 +DA:104,0 +DA:106,0 +DA:110,0 +DA:111,0 +DA:113,0 +DA:115,0 +DA:119,0 +DA:120,0 +DA:124,0 +DA:125,0 +DA:129,0 +DA:130,0 +DA:134,0 +DA:135,0 +DA:139,0 +DA:140,0 +DA:144,0 +DA:145,0 +DA:149,0 +DA:150,0 +DA:154,0 +DA:155,0 +DA:159,0 +DA:160,0 +DA:164,0 +DA:165,0 +DA:169,0 +DA:170,0 +DA:174,0 +DA:175,0 +DA:176,0 +DA:180,0 +DA:181,0 +DA:185,0 +DA:186,0 +DA:187,0 +DA:191,0 +DA:197,0 +DA:198,0 +DA:202,0 +DA:209,0 +DA:213,0 +DA:214,0 +DA:218,0 +DA:219,0 +DA:220,0 +DA:225,0 +DA:229,0 +DA:247,2 +DA:258,0 +DA:259,0 +DA:360,0 +DA:361,0 +DA:372,0 +DA:373,0 +DA:420,0 +DA:421,0 +DA:495,0 +DA:496,0 +DA:541,0 +DA:559,0 +DA:572,0 +DA:573,0 +DA:639,2 +DA:640,2 +DA:642,2 +DA:643,0 +DA:644,2 +DA:645,0 +DA:648,2 +DA:652,2 +DA:654,0 +DA:657,2 +DA:662,2 +DA:685,2 +DA:686,1 +DA:705,1 +DA:751,1 +DA:765,0 +DA:769,0 +DA:773,1 +LF:139 +LH:54 +BRDA:20,0,0,1 +BRDA:20,0,1,0 +BRDA:79,1,0,0 +BRDA:79,1,1,0 +BRDA:85,2,0,0 +BRDA:85,2,1,0 +BRDA:88,3,0,0 +BRDA:88,3,1,0 +BRDA:88,4,0,0 +BRDA:88,4,1,0 +BRDA:97,5,0,0 +BRDA:97,5,1,0 +BRDA:101,6,0,0 +BRDA:101,6,1,0 +BRDA:101,7,0,0 +BRDA:101,7,1,0 +BRDA:110,8,0,0 +BRDA:110,8,1,0 +BRDA:197,9,0,0 +BRDA:197,9,1,0 +BRDA:209,10,0,0 +BRDA:209,10,1,0 +BRDA:218,11,0,0 +BRDA:218,11,1,0 +BRDA:258,12,0,0 +BRDA:258,12,1,0 +BRDA:276,13,0,2 +BRDA:276,13,1,0 +BRDA:276,13,2,0 +BRDA:276,13,3,0 +BRDA:287,14,0,2 +BRDA:287,14,1,2 +BRDA:287,14,2,2 +BRDA:297,15,0,2 +BRDA:297,15,1,2 +BRDA:307,16,0,2 +BRDA:307,16,1,2 +BRDA:317,17,0,2 +BRDA:317,17,1,2 +BRDA:328,18,0,2 +BRDA:328,18,1,0 +BRDA:328,18,2,0 +BRDA:328,18,3,0 +BRDA:341,19,0,2 +BRDA:341,19,1,0 +BRDA:360,20,0,0 +BRDA:360,20,1,0 +BRDA:420,21,0,0 +BRDA:420,21,1,0 +BRDA:495,22,0,0 +BRDA:495,22,1,0 +BRDA:572,23,0,0 +BRDA:572,23,1,0 +BRDA:591,24,0,0 +BRDA:591,24,1,0 +BRDA:642,25,0,0 +BRDA:642,25,1,2 +BRDA:642,26,0,2 +BRDA:642,26,1,0 +BRDA:644,27,0,0 +BRDA:644,27,1,2 +BRDA:644,28,0,2 +BRDA:644,28,1,0 +BRDA:652,29,0,0 +BRDA:652,29,1,2 +BRDA:652,29,2,2 +BRF:66 +BRH:19 +end_of_record +TN: +SF:/home/lalis/git/p5.js-web-editor/client/modules/IDE/actions/console.js +FN:3,clearConsole +FN:9,dispatchConsoleEvent +FNF:2 +FNH:0 +FNDA:0,clearConsole +FNDA:0,dispatchConsoleEvent +DA:4,0 +DA:10,0 +LF:2 +LH:0 +BRF:0 +BRH:0 +end_of_record +TN: +SF:/home/lalis/git/p5.js-web-editor/client/modules/IDE/actions/files.js +FN:12,appendToFilename +FN:18,createUniqueName +FN:19,(anonymous_2) +FN:20,(anonymous_3) +FN:20,(anonymous_4) +FN:23,(anonymous_5) +FN:28,(anonymous_6) +FN:33,updateFileContent +FN:41,createFile +FN:42,(anonymous_9) +FN:54,(anonymous_10) +FN:68,(anonymous_11) +FN:94,createFolder +FN:95,(anonymous_13) +FN:107,(anonymous_14) +FN:116,(anonymous_15) +FN:138,updateFileName +FN:139,(anonymous_17) +FN:149,deleteFile +FN:150,(anonymous_19) +FN:159,(anonymous_20) +FN:166,(anonymous_21) +FN:182,showFolderChildren +FN:189,hideFolderChildren +FN:196,setBlobUrl +FN:204,getBlobUrl +FNF:26 +FNH:0 +FNDA:0,appendToFilename +FNDA:0,createUniqueName +FNDA:0,(anonymous_2) +FNDA:0,(anonymous_3) +FNDA:0,(anonymous_4) +FNDA:0,(anonymous_5) +FNDA:0,(anonymous_6) +FNDA:0,updateFileContent +FNDA:0,createFile +FNDA:0,(anonymous_9) +FNDA:0,(anonymous_10) +FNDA:0,(anonymous_11) +FNDA:0,createFolder +FNDA:0,(anonymous_13) +FNDA:0,(anonymous_14) +FNDA:0,(anonymous_15) +FNDA:0,updateFileName +FNDA:0,(anonymous_17) +FNDA:0,deleteFile +FNDA:0,(anonymous_19) +FNDA:0,(anonymous_20) +FNDA:0,(anonymous_21) +FNDA:0,showFolderChildren +FNDA:0,hideFolderChildren +FNDA:0,setBlobUrl +FNDA:0,getBlobUrl +DA:9,1 +DA:10,1 +DA:13,0 +DA:14,0 +DA:15,0 +DA:19,0 +DA:20,0 +DA:21,0 +DA:22,0 +DA:23,0 +DA:25,0 +DA:26,0 +DA:27,0 +DA:28,0 +DA:30,0 +DA:34,0 +DA:42,0 +DA:43,0 +DA:44,0 +DA:45,0 +DA:46,0 +DA:53,0 +DA:55,0 +DA:60,0 +DA:61,0 +DA:62,0 +DA:66,0 +DA:68,0 +DA:73,0 +DA:74,0 +DA:84,0 +DA:88,0 +DA:89,0 +DA:95,0 +DA:96,0 +DA:97,0 +DA:98,0 +DA:99,0 +DA:106,0 +DA:108,0 +DA:113,0 +DA:114,0 +DA:116,0 +DA:121,0 +DA:122,0 +DA:133,0 +DA:139,0 +DA:140,0 +DA:141,0 +DA:150,0 +DA:151,0 +DA:152,0 +DA:153,0 +DA:158,0 +DA:160,0 +DA:167,0 +DA:173,0 +DA:183,0 +DA:190,0 +DA:197,0 +DA:205,0 +DA:206,0 +DA:209,0 +DA:210,0 +DA:211,0 +LF:65 +LH:2 +BRDA:9,0,0,1 +BRDA:9,0,1,0 +BRDA:14,1,0,0 +BRDA:14,1,1,0 +BRDA:45,2,0,0 +BRDA:45,2,1,0 +BRDA:49,3,0,0 +BRDA:49,3,1,0 +BRDA:80,4,0,0 +BRDA:80,4,1,0 +BRDA:98,5,0,0 +BRDA:98,5,1,0 +BRDA:152,6,0,0 +BRDA:152,6,1,0 +BRDA:205,7,0,0 +BRDA:205,7,1,0 +BRF:16 +BRH:1 +end_of_record +TN: +SF:/home/lalis/git/p5.js-web-editor/client/modules/IDE/actions/ide.js +FN:4,startVisualSketch +FN:10,stopVisualSketch +FN:16,startRefreshSketch +FN:22,startSketchAndRefresh +FN:23,(anonymous_4) +FN:29,endSketchRefresh +FN:35,startAccessibleOutput +FN:41,stopAccessibleOutput +FN:47,setSelectedFile +FN:54,resetSelectedFile +FN:55,(anonymous_10) +FN:57,(anonymous_11) +FN:65,newFile +FN:72,closeNewFileModal +FN:78,openUploadFileModal +FN:85,closeUploadFileModal +FN:91,expandSidebar +FN:97,collapseSidebar +FN:103,expandConsole +FN:109,collapseConsole +FN:115,openPreferences +FN:121,closePreferences +FN:127,openProjectOptions +FN:133,closeProjectOptions +FN:139,newFolder +FN:146,closeNewFolderModal +FN:152,showShareModal +FN:153,(anonymous_27) +FN:166,closeShareModal +FN:172,showEditorOptions +FN:178,closeEditorOptions +FN:184,showKeyboardShortcutModal +FN:190,closeKeyboardShortcutModal +FN:196,setUnsavedChanges +FN:203,detectInfiniteLoops +FN:210,resetInfiniteLoops +FN:216,justOpenedProject +FN:222,resetJustOpenedProject +FN:228,setPreviousPath +FN:235,showErrorModal +FN:242,hideErrorModal +FN:248,hideRuntimeErrorWarning +FN:254,showRuntimeErrorWarning +FN:260,startSketch +FN:261,(anonymous_44) +FN:267,startAccessibleSketch +FN:268,(anonymous_46) +FN:275,stopSketch +FN:276,(anonymous_48) +FNF:49 +FNH:0 +FNDA:0,startVisualSketch +FNDA:0,stopVisualSketch +FNDA:0,startRefreshSketch +FNDA:0,startSketchAndRefresh +FNDA:0,(anonymous_4) +FNDA:0,endSketchRefresh +FNDA:0,startAccessibleOutput +FNDA:0,stopAccessibleOutput +FNDA:0,setSelectedFile +FNDA:0,resetSelectedFile +FNDA:0,(anonymous_10) +FNDA:0,(anonymous_11) +FNDA:0,newFile +FNDA:0,closeNewFileModal +FNDA:0,openUploadFileModal +FNDA:0,closeUploadFileModal +FNDA:0,expandSidebar +FNDA:0,collapseSidebar +FNDA:0,expandConsole +FNDA:0,collapseConsole +FNDA:0,openPreferences +FNDA:0,closePreferences +FNDA:0,openProjectOptions +FNDA:0,closeProjectOptions +FNDA:0,newFolder +FNDA:0,closeNewFolderModal +FNDA:0,showShareModal +FNDA:0,(anonymous_27) +FNDA:0,closeShareModal +FNDA:0,showEditorOptions +FNDA:0,closeEditorOptions +FNDA:0,showKeyboardShortcutModal +FNDA:0,closeKeyboardShortcutModal +FNDA:0,setUnsavedChanges +FNDA:0,detectInfiniteLoops +FNDA:0,resetInfiniteLoops +FNDA:0,justOpenedProject +FNDA:0,resetJustOpenedProject +FNDA:0,setPreviousPath +FNDA:0,showErrorModal +FNDA:0,hideErrorModal +FNDA:0,hideRuntimeErrorWarning +FNDA:0,showRuntimeErrorWarning +FNDA:0,startSketch +FNDA:0,(anonymous_44) +FNDA:0,startAccessibleSketch +FNDA:0,(anonymous_46) +FNDA:0,stopSketch +FNDA:0,(anonymous_48) +DA:5,0 +DA:11,0 +DA:17,0 +DA:23,0 +DA:24,0 +DA:25,0 +DA:30,0 +DA:36,0 +DA:42,0 +DA:48,0 +DA:55,0 +DA:56,0 +DA:57,0 +DA:58,0 +DA:66,0 +DA:73,0 +DA:79,0 +DA:86,0 +DA:92,0 +DA:98,0 +DA:104,0 +DA:110,0 +DA:116,0 +DA:122,0 +DA:128,0 +DA:134,0 +DA:140,0 +DA:147,0 +DA:153,0 +DA:154,0 +DA:155,0 +DA:167,0 +DA:173,0 +DA:179,0 +DA:185,0 +DA:191,0 +DA:197,0 +DA:204,0 +DA:211,0 +DA:217,0 +DA:223,0 +DA:229,0 +DA:236,0 +DA:243,0 +DA:249,0 +DA:255,0 +DA:261,0 +DA:262,0 +DA:263,0 +DA:268,0 +DA:269,0 +DA:270,0 +DA:271,0 +DA:276,0 +DA:277,0 +DA:278,0 +LF:56 +LH:0 +BRDA:57,0,0,0 +BRDA:57,0,1,0 +BRDA:158,1,0,0 +BRDA:158,1,1,0 +BRDA:159,2,0,0 +BRDA:159,2,1,0 +BRDA:160,3,0,0 +BRDA:160,3,1,0 +BRF:8 +BRH:0 +end_of_record +TN: +SF:/home/lalis/git/p5.js-web-editor/client/modules/IDE/actions/preferences.js +FN:7,updatePreferences +FN:9,(anonymous_1) +FN:11,(anonymous_2) +FN:17,setFontSize +FN:18,(anonymous_4) +FN:35,setLineNumbers +FN:36,(anonymous_6) +FN:53,setAutosave +FN:54,(anonymous_8) +FN:71,setLinewrap +FN:72,(anonymous_10) +FN:89,setLintWarning +FN:90,(anonymous_12) +FN:107,setTextOutput +FN:108,(anonymous_14) +FN:125,setGridOutput +FN:126,(anonymous_16) +FN:143,setSoundOutput +FN:144,(anonymous_18) +FN:161,setTheme +FN:166,(anonymous_20) +FN:183,setAutorefresh +FN:188,(anonymous_22) +FN:205,setAllAccessibleOutput +FN:206,(anonymous_24) +FNF:25 +FNH:0 +FNDA:0,updatePreferences +FNDA:0,(anonymous_1) +FNDA:0,(anonymous_2) +FNDA:0,setFontSize +FNDA:0,(anonymous_4) +FNDA:0,setLineNumbers +FNDA:0,(anonymous_6) +FNDA:0,setAutosave +FNDA:0,(anonymous_8) +FNDA:0,setLinewrap +FNDA:0,(anonymous_10) +FNDA:0,setLintWarning +FNDA:0,(anonymous_12) +FNDA:0,setTextOutput +FNDA:0,(anonymous_14) +FNDA:0,setGridOutput +FNDA:0,(anonymous_16) +FNDA:0,setSoundOutput +FNDA:0,(anonymous_18) +FNDA:0,setTheme +FNDA:0,(anonymous_20) +FNDA:0,setAutorefresh +FNDA:0,(anonymous_22) +FNDA:0,setAllAccessibleOutput +FNDA:0,(anonymous_24) +DA:4,1 +DA:5,1 +DA:8,0 +DA:11,0 +DA:18,0 +DA:19,0 +DA:23,0 +DA:24,0 +DA:25,0 +DA:30,0 +DA:36,0 +DA:37,0 +DA:41,0 +DA:42,0 +DA:43,0 +DA:48,0 +DA:54,0 +DA:55,0 +DA:59,0 +DA:60,0 +DA:61,0 +DA:66,0 +DA:72,0 +DA:73,0 +DA:77,0 +DA:78,0 +DA:79,0 +DA:84,0 +DA:90,0 +DA:91,0 +DA:95,0 +DA:96,0 +DA:97,0 +DA:102,0 +DA:108,0 +DA:109,0 +DA:113,0 +DA:114,0 +DA:115,0 +DA:120,0 +DA:126,0 +DA:127,0 +DA:131,0 +DA:132,0 +DA:133,0 +DA:138,0 +DA:144,0 +DA:145,0 +DA:149,0 +DA:150,0 +DA:151,0 +DA:156,0 +DA:166,0 +DA:167,0 +DA:171,0 +DA:172,0 +DA:173,0 +DA:178,0 +DA:188,0 +DA:189,0 +DA:193,0 +DA:194,0 +DA:195,0 +DA:200,0 +DA:206,0 +DA:207,0 +DA:208,0 +DA:209,0 +LF:68 +LH:2 +BRDA:4,0,0,1 +BRDA:4,0,1,0 +BRDA:24,1,0,0 +BRDA:24,1,1,0 +BRDA:42,2,0,0 +BRDA:42,2,1,0 +BRDA:60,3,0,0 +BRDA:60,3,1,0 +BRDA:78,4,0,0 +BRDA:78,4,1,0 +BRDA:96,5,0,0 +BRDA:96,5,1,0 +BRDA:114,6,0,0 +BRDA:114,6,1,0 +BRDA:132,7,0,0 +BRDA:132,7,1,0 +BRDA:150,8,0,0 +BRDA:150,8,1,0 +BRDA:172,9,0,0 +BRDA:172,9,1,0 +BRDA:194,10,0,0 +BRDA:194,10,1,0 +BRF:22 +BRH:1 +end_of_record +TN: +SF:/home/lalis/git/p5.js-web-editor/client/modules/IDE/actions/project.js +FN:20,setProject +FN:29,setProjectName +FN:36,projectSaveFail +FN:43,setNewProject +FN:52,getProject +FN:53,(anonymous_5) +FN:56,(anonymous_6) +FN:60,(anonymous_7) +FN:67,persistState +FN:68,(anonymous_9) +FN:77,clearPersistedState +FN:78,(anonymous_11) +FN:86,startSavingProject +FN:92,endSavingProject +FN:98,projectSaveSuccess +FN:105,getSynchedProject +FN:108,(anonymous_16) +FN:109,(anonymous_17) +FN:124,saveProject +FN:125,(anonymous_19) +FN:138,(anonymous_20) +FN:143,(anonymous_21) +FN:156,(anonymous_22) +FN:164,(anonymous_23) +FN:177,(anonymous_24) +FN:195,(anonymous_25) +FN:203,(anonymous_26) +FN:214,autosaveProject +FN:215,(anonymous_28) +FN:220,exportProjectAsZip +FN:225,resetProject +FN:231,newProject +FN:232,(anonymous_32) +FN:238,generateNewIdsForChildren +FN:240,(anonymous_34) +FN:241,(anonymous_35) +FN:251,cloneProject +FN:252,(anonymous_37) +FN:254,(anonymous_38) +FN:259,(anonymous_39) +FN:260,(anonymous_40) +FN:267,(anonymous_41) +FN:268,(anonymous_42) +FN:273,(anonymous_43) +FN:280,(anonymous_44) +FN:286,(anonymous_45) +FN:293,(anonymous_46) +FN:297,(anonymous_47) +FN:301,(anonymous_48) +FN:310,showEditProjectName +FN:316,hideEditProjectName +FN:322,setProjectSavedTime +FN:329,changeProjectName +FN:330,(anonymous_53) +FN:333,(anonymous_54) +FN:347,(anonymous_55) +FN:357,deleteProject +FN:358,(anonymous_57) +FN:360,(anonymous_58) +FN:371,(anonymous_59) +FNF:60 +FNH:0 +FNDA:0,setProject +FNDA:0,setProjectName +FNDA:0,projectSaveFail +FNDA:0,setNewProject +FNDA:0,getProject +FNDA:0,(anonymous_5) +FNDA:0,(anonymous_6) +FNDA:0,(anonymous_7) +FNDA:0,persistState +FNDA:0,(anonymous_9) +FNDA:0,clearPersistedState +FNDA:0,(anonymous_11) +FNDA:0,startSavingProject +FNDA:0,endSavingProject +FNDA:0,projectSaveSuccess +FNDA:0,getSynchedProject +FNDA:0,(anonymous_16) +FNDA:0,(anonymous_17) +FNDA:0,saveProject +FNDA:0,(anonymous_19) +FNDA:0,(anonymous_20) +FNDA:0,(anonymous_21) +FNDA:0,(anonymous_22) +FNDA:0,(anonymous_23) +FNDA:0,(anonymous_24) +FNDA:0,(anonymous_25) +FNDA:0,(anonymous_26) +FNDA:0,autosaveProject +FNDA:0,(anonymous_28) +FNDA:0,exportProjectAsZip +FNDA:0,resetProject +FNDA:0,newProject +FNDA:0,(anonymous_32) +FNDA:0,generateNewIdsForChildren +FNDA:0,(anonymous_34) +FNDA:0,(anonymous_35) +FNDA:0,cloneProject +FNDA:0,(anonymous_37) +FNDA:0,(anonymous_38) +FNDA:0,(anonymous_39) +FNDA:0,(anonymous_40) +FNDA:0,(anonymous_41) +FNDA:0,(anonymous_42) +FNDA:0,(anonymous_43) +FNDA:0,(anonymous_44) +FNDA:0,(anonymous_45) +FNDA:0,(anonymous_46) +FNDA:0,(anonymous_47) +FNDA:0,(anonymous_48) +FNDA:0,showEditProjectName +FNDA:0,hideEditProjectName +FNDA:0,setProjectSavedTime +FNDA:0,changeProjectName +FNDA:0,(anonymous_53) +FNDA:0,(anonymous_54) +FNDA:0,(anonymous_55) +FNDA:0,deleteProject +FNDA:0,(anonymous_57) +FNDA:0,(anonymous_58) +FNDA:0,(anonymous_59) +DA:17,2 +DA:18,2 +DA:21,0 +DA:30,0 +DA:37,0 +DA:44,0 +DA:53,0 +DA:54,0 +DA:55,0 +DA:57,0 +DA:58,0 +DA:60,0 +DA:68,0 +DA:69,0 +DA:72,0 +DA:73,0 +DA:78,0 +DA:79,0 +DA:82,0 +DA:87,0 +DA:93,0 +DA:99,0 +DA:106,0 +DA:107,0 +DA:108,0 +DA:109,0 +DA:110,0 +DA:111,0 +DA:112,0 +DA:114,0 +DA:115,0 +DA:116,0 +DA:118,0 +DA:125,0 +DA:126,0 +DA:127,0 +DA:128,0 +DA:130,0 +DA:131,0 +DA:132,0 +DA:134,0 +DA:135,0 +DA:137,0 +DA:138,0 +DA:139,0 +DA:141,0 +DA:142,0 +DA:144,0 +DA:145,0 +DA:146,0 +DA:147,0 +DA:148,0 +DA:150,0 +DA:151,0 +DA:152,0 +DA:153,0 +DA:154,0 +DA:155,0 +DA:156,0 +DA:157,0 +DA:159,0 +DA:160,0 +DA:165,0 +DA:166,0 +DA:167,0 +DA:168,0 +DA:169,0 +DA:171,0 +DA:176,0 +DA:178,0 +DA:179,0 +DA:180,0 +DA:181,0 +DA:182,0 +DA:183,0 +DA:184,0 +DA:186,0 +DA:187,0 +DA:188,0 +DA:190,0 +DA:191,0 +DA:192,0 +DA:193,0 +DA:194,0 +DA:195,0 +DA:196,0 +DA:198,0 +DA:199,0 +DA:204,0 +DA:205,0 +DA:206,0 +DA:208,0 +DA:215,0 +DA:216,0 +DA:221,0 +DA:222,0 +DA:226,0 +DA:232,0 +DA:233,0 +DA:235,0 +DA:239,0 +DA:240,0 +DA:241,0 +DA:242,0 +DA:243,0 +DA:244,0 +DA:245,0 +DA:246,0 +DA:248,0 +DA:252,0 +DA:253,0 +DA:254,0 +DA:255,0 +DA:256,0 +DA:258,0 +DA:259,0 +DA:260,0 +DA:268,0 +DA:269,0 +DA:273,0 +DA:274,0 +DA:275,0 +DA:276,0 +DA:277,0 +DA:280,0 +DA:281,0 +DA:282,0 +DA:285,0 +DA:287,0 +DA:288,0 +DA:291,0 +DA:295,0 +DA:296,0 +DA:298,0 +DA:299,0 +DA:301,0 +DA:311,0 +DA:317,0 +DA:323,0 +DA:330,0 +DA:331,0 +DA:332,0 +DA:334,0 +DA:335,0 +DA:339,0 +DA:340,0 +DA:348,0 +DA:349,0 +DA:358,0 +DA:359,0 +DA:361,0 +DA:362,0 +DA:363,0 +DA:364,0 +DA:366,0 +DA:372,0 +DA:373,0 +DA:375,0 +LF:158 +LH:2 +BRDA:17,0,0,2 +BRDA:17,0,1,0 +BRDA:110,1,0,0 +BRDA:110,1,1,0 +BRDA:114,2,0,0 +BRDA:114,2,1,0 +BRDA:124,3,0,0 +BRDA:124,4,0,0 +BRDA:127,5,0,0 +BRDA:127,5,1,0 +BRDA:131,6,0,0 +BRDA:131,6,1,0 +BRDA:131,7,0,0 +BRDA:131,7,1,0 +BRDA:131,7,2,0 +BRDA:137,8,0,0 +BRDA:137,8,1,0 +BRDA:141,9,0,0 +BRDA:141,9,1,0 +BRDA:147,10,0,0 +BRDA:147,10,1,0 +BRDA:152,11,0,0 +BRDA:152,11,1,0 +BRDA:153,12,0,0 +BRDA:153,12,1,0 +BRDA:153,13,0,0 +BRDA:153,13,1,0 +BRDA:166,14,0,0 +BRDA:166,14,1,0 +BRDA:168,15,0,0 +BRDA:168,15,1,0 +BRDA:180,16,0,0 +BRDA:180,16,1,0 +BRDA:191,17,0,0 +BRDA:191,17,1,0 +BRDA:192,18,0,0 +BRDA:192,18,1,0 +BRDA:205,19,0,0 +BRDA:205,19,1,0 +BRDA:255,20,0,0 +BRDA:255,20,1,0 +BRDA:281,21,0,0 +BRDA:281,21,1,0 +BRDA:281,22,0,0 +BRDA:281,22,1,0 +BRDA:334,23,0,0 +BRDA:334,23,1,0 +BRDA:339,24,0,0 +BRDA:339,24,1,0 +BRDA:362,25,0,0 +BRDA:362,25,1,0 +BRDA:372,26,0,0 +BRDA:372,26,1,0 +BRF:53 +BRH:1 +end_of_record +TN: +SF:/home/lalis/git/p5.js-web-editor/client/modules/IDE/actions/toast.js +FN:3,hideToast +FN:9,showToast +FN:10,(anonymous_2) +FN:14,(anonymous_3) +FN:18,setToastText +FNF:5 +FNH:0 +FNDA:0,hideToast +FNDA:0,showToast +FNDA:0,(anonymous_2) +FNDA:0,(anonymous_3) +FNDA:0,setToastText +DA:4,0 +DA:10,0 +DA:11,0 +DA:14,0 +DA:19,0 +LF:5 +LH:0 +BRF:0 +BRH:0 +end_of_record +TN: +SF:/home/lalis/git/p5.js-web-editor/client/modules/IDE/components/FileNode.jsx +FN:16,(anonymous_0) +FN:38,(anonymous_1) +FN:42,(anonymous_2) +FN:44,(anonymous_3) +FN:51,(anonymous_4) +FN:55,(anonymous_5) +FN:64,(anonymous_6) +FN:71,(anonymous_7) +FN:76,(anonymous_8) +FN:82,(anonymous_9) +FN:98,(anonymous_10) +FN:111,(anonymous_11) +FN:115,(anonymous_12) +FN:119,(anonymous_13) +FN:123,(anonymous_14) +FN:131,(anonymous_15) +FN:143,(anonymous_16) +FN:148,(anonymous_17) +FN:160,(anonymous_18) +FN:166,(anonymous_19) +FN:180,(anonymous_20) +FN:181,(anonymous_21) +FN:190,(anonymous_22) +FN:200,(anonymous_23) +FN:206,(anonymous_24) +FN:208,(anonymous_25) +FN:220,(anonymous_26) +FN:226,(anonymous_27) +FN:228,(anonymous_28) +FN:242,(anonymous_29) +FN:245,(anonymous_30) +FN:246,(anonymous_31) +FN:257,(anonymous_32) +FN:261,(anonymous_33) +FN:277,(anonymous_34) +FN:316,mapStateToProps +FN:318,(anonymous_36) +FN:321,mapDispatchToProps +FNF:38 +FNH:15 +FNDA:3,(anonymous_0) +FNDA:0,(anonymous_1) +FNDA:0,(anonymous_2) +FNDA:0,(anonymous_3) +FNDA:71,(anonymous_4) +FNDA:1,(anonymous_5) +FNDA:0,(anonymous_6) +FNDA:2,(anonymous_7) +FNDA:0,(anonymous_8) +FNDA:2,(anonymous_9) +FNDA:0,(anonymous_10) +FNDA:0,(anonymous_11) +FNDA:2,(anonymous_12) +FNDA:2,(anonymous_13) +FNDA:0,(anonymous_14) +FNDA:13,(anonymous_15) +FNDA:13,(anonymous_16) +FNDA:13,(anonymous_17) +FNDA:0,(anonymous_18) +FNDA:0,(anonymous_19) +FNDA:0,(anonymous_20) +FNDA:2,(anonymous_21) +FNDA:0,(anonymous_22) +FNDA:13,(anonymous_23) +FNDA:0,(anonymous_24) +FNDA:0,(anonymous_25) +FNDA:13,(anonymous_26) +FNDA:0,(anonymous_27) +FNDA:0,(anonymous_28) +FNDA:2,(anonymous_29) +FNDA:0,(anonymous_30) +FNDA:0,(anonymous_31) +FNDA:0,(anonymous_32) +FNDA:0,(anonymous_33) +FNDA:13,(anonymous_34) +FNDA:0,mapStateToProps +FNDA:0,(anonymous_36) +FNDA:0,mapDispatchToProps +DA:10,1 +DA:11,1 +DA:12,1 +DA:13,1 +DA:17,3 +DA:18,3 +DA:19,3 +DA:20,3 +DA:21,3 +DA:22,3 +DA:23,3 +DA:24,3 +DA:25,3 +DA:26,3 +DA:27,3 +DA:28,3 +DA:30,3 +DA:39,0 +DA:43,0 +DA:44,0 +DA:45,0 +DA:46,0 +DA:52,71 +DA:56,1 +DA:57,1 +DA:59,1 +DA:60,1 +DA:65,0 +DA:66,0 +DA:67,0 +DA:72,2 +DA:73,2 +DA:77,0 +DA:78,0 +DA:83,2 +DA:84,2 +DA:85,2 +DA:86,2 +DA:87,2 +DA:88,2 +DA:89,2 +DA:91,2 +DA:92,2 +DA:93,2 +DA:94,1 +DA:95,1 +DA:99,0 +DA:100,0 +DA:101,0 +DA:103,0 +DA:104,0 +DA:106,0 +DA:107,0 +DA:112,0 +DA:116,2 +DA:120,2 +DA:124,0 +DA:132,13 +DA:141,13 +DA:144,13 +DA:145,13 +DA:149,13 +DA:150,0 +DA:156,13 +DA:160,0 +DA:166,0 +DA:180,0 +DA:182,2 +DA:183,2 +DA:190,0 +DA:201,13 +DA:202,0 +DA:207,0 +DA:208,0 +DA:221,13 +DA:222,0 +DA:227,0 +DA:228,0 +DA:243,2 +DA:244,2 +DA:245,2 +DA:246,2 +DA:258,0 +DA:259,0 +DA:260,0 +DA:261,0 +DA:278,13 +DA:279,13 +DA:291,1 +DA:310,1 +DA:318,0 +DA:322,0 +DA:325,1 +LF:93 +LH:57 +BRDA:45,0,0,0 +BRDA:45,0,1,0 +BRDA:59,1,0,1 +BRDA:59,1,1,0 +BRDA:66,2,0,0 +BRDA:66,2,1,0 +BRDA:66,3,0,0 +BRDA:66,3,1,0 +BRDA:77,4,0,0 +BRDA:77,4,1,0 +BRDA:87,5,0,2 +BRDA:87,5,1,2 +BRDA:88,6,0,2 +BRDA:88,6,1,0 +BRDA:89,7,0,2 +BRDA:89,7,1,2 +BRDA:89,7,2,1 +BRDA:92,8,0,2 +BRDA:92,8,1,1 +BRDA:93,9,0,1 +BRDA:93,9,1,1 +BRDA:93,10,0,2 +BRDA:93,10,1,1 +BRDA:93,10,2,1 +BRDA:93,10,3,1 +BRDA:93,10,4,1 +BRDA:100,11,0,0 +BRDA:100,11,1,0 +BRDA:103,12,0,0 +BRDA:103,12,1,0 +BRDA:144,13,0,13 +BRDA:144,13,1,0 +BRDA:149,14,0,0 +BRDA:149,14,1,13 +BRDA:201,15,0,0 +BRDA:201,15,1,13 +BRDA:221,16,0,0 +BRDA:221,16,1,13 +BRDA:258,17,0,0 +BRDA:258,17,1,0 +BRDA:278,18,0,13 +BRDA:278,18,1,0 +BRDA:318,19,0,0 +BRDA:318,19,1,0 +BRF:44 +BRH:21 +end_of_record +TN: +SF:/home/lalis/git/p5.js-web-editor/client/modules/User/actions.js +FN:11,authError +FN:18,signUpUser +FN:19,(anonymous_2) +FN:21,(anonymous_3) +FN:29,(anonymous_4) +FN:33,loginUser +FN:37,loginUserSuccess +FN:44,loginUserFailure +FN:51,validateAndLoginUser +FN:52,(anonymous_9) +FN:54,(anonymous_10) +FN:67,(anonymous_11) +FN:72,getUser +FN:73,(anonymous_13) +FN:75,(anonymous_14) +FN:85,(anonymous_15) +FN:92,validateSession +FN:93,(anonymous_17) +FN:95,(anonymous_18) +FN:101,(anonymous_19) +FN:109,logoutUser +FN:110,(anonymous_21) +FN:112,(anonymous_22) +FN:117,(anonymous_23) +FN:121,initiateResetPassword +FN:122,(anonymous_25) +FN:127,(anonymous_26) +FN:130,(anonymous_27) +FN:137,initiateVerification +FN:138,(anonymous_29) +FN:143,(anonymous_30) +FN:146,(anonymous_31) +FN:153,verifyEmailConfirmation +FN:154,(anonymous_33) +FN:160,(anonymous_34) +FN:164,(anonymous_35) +FN:172,resetPasswordReset +FN:178,validateResetPasswordToken +FN:179,(anonymous_38) +FN:181,(anonymous_39) +FN:184,(anonymous_40) +FN:190,updatePassword +FN:191,(anonymous_42) +FN:193,(anonymous_43) +FN:197,(anonymous_44) +FN:203,updateSettingsSuccess +FN:210,updateSettings +FN:211,(anonymous_47) +FN:213,(anonymous_48) +FN:219,(anonymous_49) +FN:222,createApiKeySuccess +FN:229,createApiKey +FN:230,(anonymous_52) +FN:232,(anonymous_53) +FN:235,(anonymous_54) +FN:238,removeApiKey +FN:239,(anonymous_56) +FN:241,(anonymous_57) +FN:247,(anonymous_58) +FNF:59 +FNH:0 +FNDA:0,authError +FNDA:0,signUpUser +FNDA:0,(anonymous_2) +FNDA:0,(anonymous_3) +FNDA:0,(anonymous_4) +FNDA:0,loginUser +FNDA:0,loginUserSuccess +FNDA:0,loginUserFailure +FNDA:0,validateAndLoginUser +FNDA:0,(anonymous_9) +FNDA:0,(anonymous_10) +FNDA:0,(anonymous_11) +FNDA:0,getUser +FNDA:0,(anonymous_13) +FNDA:0,(anonymous_14) +FNDA:0,(anonymous_15) +FNDA:0,validateSession +FNDA:0,(anonymous_17) +FNDA:0,(anonymous_18) +FNDA:0,(anonymous_19) +FNDA:0,logoutUser +FNDA:0,(anonymous_21) +FNDA:0,(anonymous_22) +FNDA:0,(anonymous_23) +FNDA:0,initiateResetPassword +FNDA:0,(anonymous_25) +FNDA:0,(anonymous_26) +FNDA:0,(anonymous_27) +FNDA:0,initiateVerification +FNDA:0,(anonymous_29) +FNDA:0,(anonymous_30) +FNDA:0,(anonymous_31) +FNDA:0,verifyEmailConfirmation +FNDA:0,(anonymous_33) +FNDA:0,(anonymous_34) +FNDA:0,(anonymous_35) +FNDA:0,resetPasswordReset +FNDA:0,validateResetPasswordToken +FNDA:0,(anonymous_38) +FNDA:0,(anonymous_39) +FNDA:0,(anonymous_40) +FNDA:0,updatePassword +FNDA:0,(anonymous_42) +FNDA:0,(anonymous_43) +FNDA:0,(anonymous_44) +FNDA:0,updateSettingsSuccess +FNDA:0,updateSettings +FNDA:0,(anonymous_47) +FNDA:0,(anonymous_48) +FNDA:0,(anonymous_49) +FNDA:0,createApiKeySuccess +FNDA:0,createApiKey +FNDA:0,(anonymous_52) +FNDA:0,(anonymous_53) +FNDA:0,(anonymous_54) +FNDA:0,removeApiKey +FNDA:0,(anonymous_56) +FNDA:0,(anonymous_57) +FNDA:0,(anonymous_58) +DA:8,1 +DA:9,1 +DA:12,0 +DA:19,0 +DA:20,0 +DA:22,0 +DA:26,0 +DA:27,0 +DA:29,0 +DA:34,0 +DA:38,0 +DA:45,0 +DA:52,0 +DA:53,0 +DA:55,0 +DA:59,0 +DA:63,0 +DA:64,0 +DA:65,0 +DA:68,0 +DA:73,0 +DA:74,0 +DA:76,0 +DA:80,0 +DA:86,0 +DA:87,0 +DA:93,0 +DA:94,0 +DA:96,0 +DA:97,0 +DA:98,0 +DA:102,0 +DA:103,0 +DA:110,0 +DA:111,0 +DA:113,0 +DA:117,0 +DA:122,0 +DA:123,0 +DA:126,0 +DA:130,0 +DA:138,0 +DA:139,0 +DA:142,0 +DA:146,0 +DA:154,0 +DA:155,0 +DA:159,0 +DA:160,0 +DA:164,0 +DA:173,0 +DA:179,0 +DA:180,0 +DA:184,0 +DA:191,0 +DA:192,0 +DA:194,0 +DA:195,0 +DA:197,0 +DA:204,0 +DA:211,0 +DA:212,0 +DA:214,0 +DA:215,0 +DA:216,0 +DA:217,0 +DA:219,0 +DA:223,0 +DA:230,0 +DA:231,0 +DA:233,0 +DA:235,0 +DA:239,0 +DA:240,0 +DA:242,0 +DA:247,0 +LF:76 +LH:2 +BRDA:8,0,0,1 +BRDA:8,0,1,0 +BRDA:86,1,0,0 +BRDA:86,1,1,0 +BRDA:97,2,0,0 +BRDA:97,2,1,0 +BRDA:102,3,0,0 +BRDA:102,3,1,0 +BRF:8 +BRH:1 +end_of_record +TN: +SF:/home/lalis/git/p5.js-web-editor/client/utils/metaKey.js +FN:1,(anonymous_0) +FNF:1 +FNH:1 +FNDA:1,(anonymous_0) +DA:1,1 +DA:2,1 +DA:3,1 +DA:8,0 +DA:11,1 +LF:5 +LH:4 +BRDA:2,0,0,1 +BRDA:2,0,1,0 +BRDA:2,1,0,1 +BRDA:2,1,1,1 +BRDA:3,2,0,0 +BRDA:3,2,1,1 +BRDA:11,3,0,0 +BRDA:11,3,1,1 +BRF:8 +BRH:5 +end_of_record +TN: +SF:/home/lalis/git/p5.js-web-editor/server/controllers/project.controller/createProject.js +FN:4,createProject +FN:11,sendFailure +FN:15,populateUserData +FN:19,(anonymous_3) +FN:36,apiCreateProject +FN:39,sendValidationErrors +FN:48,sendFailure +FN:52,handleErrors +FN:62,checkUserHasPermission +FN:78,(anonymous_9) +FN:81,(anonymous_10) +FNF:11 +FNH:10 +FNDA:4,createProject +FNDA:2,sendFailure +FNDA:3,populateUserData +FNDA:3,(anonymous_3) +FNDA:6,apiCreateProject +FNDA:5,sendValidationErrors +FNDA:0,sendFailure +FNDA:5,handleErrors +FNDA:7,checkUserHasPermission +FNDA:2,(anonymous_9) +FNDA:1,(anonymous_10) +DA:5,4 +DA:9,4 +DA:12,2 +DA:16,3 +DA:20,3 +DA:21,1 +DA:22,1 +DA:24,2 +DA:30,4 +DA:37,6 +DA:40,5 +DA:49,0 +DA:53,5 +DA:54,3 +DA:55,2 +DA:56,2 +DA:58,0 +DA:63,7 +DA:64,1 +DA:65,1 +DA:66,1 +DA:68,1 +DA:72,6 +DA:73,6 +DA:75,5 +DA:77,2 +DA:79,2 +DA:80,1 +DA:82,1 +DA:86,1 +DA:87,1 +DA:89,1 +DA:94,4 +DA:95,4 +LF:34 +LH:32 +BRDA:20,0,0,1 +BRDA:20,0,1,2 +BRDA:39,1,0,3 +BRDA:53,2,0,3 +BRDA:53,2,1,2 +BRDA:55,3,0,2 +BRDA:55,3,1,0 +BRDA:63,4,0,1 +BRDA:63,4,1,6 +BRDA:79,5,0,1 +BRDA:79,5,1,1 +BRF:11 +BRH:10 +end_of_record +TN: +SF:/home/lalis/git/p5.js-web-editor/server/controllers/project.controller/deleteProject.js +FN:8,deleteFilesFromS3 +FN:9,(anonymous_1) +FN:19,(anonymous_2) +FN:22,deleteProject +FN:23,sendFailure +FN:27,sendProjectNotFound +FN:31,handleProjectDeletion +FN:44,(anonymous_7) +FNF:8 +FNH:6 +FNDA:1,deleteFilesFromS3 +FNDA:0,(anonymous_1) +FNDA:0,(anonymous_2) +FNDA:3,deleteProject +FNDA:2,sendFailure +FNDA:1,sendProjectNotFound +FNDA:3,handleProjectDeletion +FNDA:1,(anonymous_7) +DA:6,1 +DA:9,1 +DA:10,0 +DA:11,0 +DA:14,0 +DA:17,0 +DA:19,0 +DA:24,2 +DA:28,1 +DA:32,3 +DA:33,1 +DA:34,1 +DA:37,2 +DA:38,1 +DA:39,1 +DA:42,1 +DA:44,1 +DA:45,1 +DA:46,0 +DA:47,0 +DA:50,1 +DA:54,3 +LF:22 +LH:15 +BRDA:10,0,0,0 +BRDA:10,0,1,0 +BRDA:11,1,0,0 +BRDA:11,1,1,0 +BRDA:11,2,0,0 +BRDA:11,2,1,0 +BRDA:11,2,2,0 +BRDA:32,3,0,1 +BRDA:32,3,1,2 +BRDA:37,4,0,1 +BRDA:37,4,1,1 +BRDA:45,5,0,0 +BRDA:45,5,1,1 +BRF:13 +BRH:5 +end_of_record +TN: +SF:/home/lalis/git/p5.js-web-editor/server/controllers/project.controller/getProjectsForUser.js +FN:8,getProjectsForUserName +FN:9,(anonymous_1) +FN:10,(anonymous_2) +FN:24,(anonymous_3) +FN:36,getProjectsForUser +FN:39,(anonymous_5) +FN:40,(anonymous_6) +FN:54,apiGetProjectsForUser +FN:57,(anonymous_8) +FN:58,(anonymous_9) +FN:61,(anonymous_10) +FNF:11 +FNH:7 +FNDA:4,getProjectsForUserName +FNDA:4,(anonymous_1) +FNDA:4,(anonymous_2) +FNDA:0,(anonymous_3) +FNDA:3,getProjectsForUser +FNDA:0,(anonymous_5) +FNDA:2,(anonymous_6) +FNDA:3,apiGetProjectsForUser +FNDA:0,(anonymous_8) +FNDA:0,(anonymous_9) +FNDA:2,(anonymous_10) +DA:6,1 +DA:9,4 +DA:10,4 +DA:11,4 +DA:12,2 +DA:13,2 +DA:16,2 +DA:17,2 +DA:18,2 +DA:21,0 +DA:25,0 +DA:26,0 +DA:27,0 +DA:30,0 +DA:37,3 +DA:38,2 +DA:39,0 +DA:41,2 +DA:42,1 +DA:44,1 +DA:50,1 +DA:51,1 +DA:55,3 +DA:56,2 +DA:58,0 +DA:59,0 +DA:62,2 +DA:63,1 +DA:65,1 +DA:70,1 +DA:71,1 +LF:31 +LH:23 +BRDA:11,0,0,2 +BRDA:11,0,1,2 +BRDA:16,1,0,2 +BRDA:16,1,1,0 +BRDA:25,2,0,0 +BRDA:25,2,1,0 +BRDA:37,3,0,2 +BRDA:37,3,1,1 +BRDA:41,4,0,1 +BRDA:41,4,1,1 +BRDA:55,5,0,2 +BRDA:55,5,1,1 +BRDA:62,6,0,1 +BRDA:62,6,1,1 +BRF:14 +BRH:11 +end_of_record +TN: +SF:/home/lalis/git/p5.js-web-editor/server/controllers/user.controller/apiKey.js +FN:9,generateApiKey +FN:10,(anonymous_1) +FN:11,(anonymous_2) +FN:21,createApiKey +FN:22,(anonymous_4) +FN:23,sendFailure +FN:28,(anonymous_6) +FN:43,(anonymous_7) +FN:50,(anonymous_8) +FN:66,removeApiKey +FN:67,(anonymous_10) +FN:68,sendFailure +FN:73,(anonymous_12) +FN:84,(anonymous_13) +FN:92,(anonymous_14) +FNF:15 +FNH:15 +FNDA:1,generateApiKey +FNDA:1,(anonymous_1) +FNDA:1,(anonymous_2) +FNDA:3,createApiKey +FNDA:3,(anonymous_4) +FNDA:2,sendFailure +FNDA:3,(anonymous_6) +FNDA:1,(anonymous_7) +FNDA:1,(anonymous_8) +FNDA:3,removeApiKey +FNDA:3,(anonymous_10) +FNDA:2,sendFailure +FNDA:3,(anonymous_12) +FNDA:1,(anonymous_13) +FNDA:1,(anonymous_14) +DA:10,1 +DA:11,1 +DA:12,1 +DA:13,0 +DA:15,1 +DA:16,1 +DA:22,3 +DA:24,2 +DA:25,2 +DA:28,3 +DA:29,3 +DA:30,1 +DA:31,1 +DA:34,2 +DA:35,1 +DA:36,1 +DA:39,1 +DA:41,1 +DA:43,1 +DA:44,1 +DA:45,0 +DA:46,0 +DA:49,1 +DA:51,1 +DA:52,1 +DA:54,1 +DA:59,1 +DA:60,1 +DA:67,3 +DA:69,2 +DA:70,2 +DA:73,3 +DA:74,3 +DA:75,0 +DA:76,0 +DA:79,3 +DA:80,1 +DA:81,1 +DA:84,2 +DA:85,2 +DA:86,1 +DA:87,1 +DA:90,1 +DA:92,1 +DA:93,1 +DA:94,0 +DA:95,0 +DA:98,1 +DA:99,1 +LF:49 +LH:42 +BRDA:12,0,0,0 +BRDA:12,0,1,1 +BRDA:29,1,0,1 +BRDA:29,1,1,2 +BRDA:34,2,0,1 +BRDA:34,2,1,1 +BRDA:44,3,0,0 +BRDA:44,3,1,1 +BRDA:54,4,0,1 +BRDA:54,4,1,0 +BRDA:74,5,0,0 +BRDA:74,5,1,3 +BRDA:79,6,0,1 +BRDA:79,6,1,2 +BRDA:85,7,0,1 +BRDA:85,7,1,1 +BRDA:93,8,0,0 +BRDA:93,8,1,1 +BRF:18 +BRH:13 +end_of_record +TN: +SF:/home/lalis/git/p5.js-web-editor/server/domain-objects/Project.js +FN:16,toApi +FN:31,transformFilesInner +FN:35,(anonymous_2) +FN:82,transformFiles +FN:95,(anonymous_4) +FN:106,containsRootHtmlFile +FN:107,(anonymous_6) +FN:115,toModel +FNF:8 +FNH:7 +FNDA:0,toApi +FNDA:40,transformFilesInner +FNDA:52,(anonymous_2) +FNDA:17,transformFiles +FNDA:5,(anonymous_4) +FNDA:14,containsRootHtmlFile +FNDA:11,(anonymous_6) +FNDA:11,toModel +DA:8,3 +DA:9,3 +DA:17,0 +DA:32,40 +DA:33,40 +DA:35,40 +DA:36,52 +DA:37,52 +DA:39,52 +DA:40,23 +DA:47,23 +DA:51,23 +DA:52,23 +DA:53,23 +DA:55,29 +DA:61,29 +DA:62,1 +DA:63,28 +DA:64,23 +DA:66,5 +DA:69,29 +DA:74,52 +DA:75,35 +DA:79,40 +DA:83,17 +DA:89,17 +DA:91,17 +DA:92,4 +DA:95,5 +DA:97,4 +DA:98,4 +DA:100,4 +DA:103,13 +DA:107,14 +DA:116,11 +DA:117,11 +DA:119,11 +DA:120,8 +DA:121,5 +DA:124,8 +DA:126,3 +DA:129,6 +DA:130,6 +DA:132,6 +LF:44 +LH:43 +BRDA:31,0,0,0 +BRDA:39,1,0,23 +BRDA:39,1,1,29 +BRDA:61,2,0,1 +BRDA:61,2,1,28 +BRDA:63,3,0,23 +BRDA:63,3,1,5 +BRDA:74,4,0,35 +BRDA:74,4,1,17 +BRDA:82,5,0,0 +BRDA:91,6,0,4 +BRDA:91,6,1,13 +BRDA:119,7,0,8 +BRDA:119,7,1,3 +BRDA:120,8,0,5 +BRDA:120,8,1,3 +BRF:16 +BRH:14 +end_of_record +TN: +SF:/home/lalis/git/p5.js-web-editor/server/domain-objects/createDefaultFiles.js +FN:36,createDefaultFiles +FNF:1 +FNH:1 +FNDA:5,createDefaultFiles +DA:1,3 +DA:10,3 +DA:27,3 +DA:37,5 +LF:4 +LH:4 +BRF:0 +BRH:0 +end_of_record +TN: +SF:/home/lalis/git/p5.js-web-editor/server/models/project.js +FN:22,getFileId +FN:42,getProjectId +FN:50,generateSlug +FN:63,isSlugUnique +FN:74,(anonymous_4) +FNF:5 +FNH:2 +FNDA:0,getFileId +FNDA:3,getProjectId +FNDA:5,generateSlug +FNDA:0,isSlugUnique +FNDA:0,(anonymous_4) +DA:8,5 +DA:10,5 +DA:22,5 +DA:23,0 +DA:26,5 +DA:30,5 +DA:42,5 +DA:43,3 +DA:46,5 +DA:50,5 +DA:51,5 +DA:53,5 +DA:54,5 +DA:57,5 +DA:63,5 +DA:64,0 +DA:65,0 +DA:67,0 +DA:68,0 +DA:72,0 +DA:74,0 +DA:77,0 +DA:78,0 +DA:81,0 +DA:83,0 +DA:84,0 +DA:87,0 +LF:27 +LH:14 +BRDA:53,0,0,5 +BRDA:53,0,1,0 +BRDA:74,1,0,0 +BRDA:74,1,1,0 +BRDA:77,2,0,0 +BRDA:77,2,1,0 +BRDA:83,3,0,0 +BRDA:83,3,1,0 +BRF:8 +BRH:1 +end_of_record +TN: +SF:/home/lalis/git/p5.js-web-editor/server/models/user.js +FN:19,getApiKeyId +FN:28,apiKeyMetadata +FN:76,checkPassword +FN:79,(anonymous_3) +FN:81,(anonymous_4) +FN:92,checkApiKey +FN:96,(anonymous_6) +FN:99,(anonymous_7) +FN:101,(anonymous_8) +FN:112,idToString +FN:123,comparePassword +FN:125,(anonymous_11) +FN:133,findMatchingKey +FN:135,(anonymous_13) +FN:144,findByMailOrName +FNF:15 +FNH:2 +FNDA:3,getApiKeyId +FNDA:1,apiKeyMetadata +FNDA:0,checkPassword +FNDA:0,(anonymous_3) +FNDA:0,(anonymous_4) +FNDA:0,checkApiKey +FNDA:0,(anonymous_6) +FNDA:0,(anonymous_7) +FNDA:0,(anonymous_8) +FNDA:0,idToString +FNDA:0,comparePassword +FNDA:0,(anonymous_11) +FNDA:0,findMatchingKey +FNDA:0,(anonymous_13) +FNDA:0,findByMailOrName +DA:3,6 +DA:5,6 +DA:11,6 +DA:13,6 +DA:19,6 +DA:20,3 +DA:29,1 +DA:34,6 +DA:38,6 +DA:43,6 +DA:76,6 +DA:77,0 +DA:78,0 +DA:79,0 +DA:80,0 +DA:81,0 +DA:82,0 +DA:83,0 +DA:84,0 +DA:92,6 +DA:93,0 +DA:94,0 +DA:95,0 +DA:96,0 +DA:97,0 +DA:98,0 +DA:99,0 +DA:100,0 +DA:101,0 +DA:102,0 +DA:103,0 +DA:104,0 +DA:109,0 +DA:112,6 +DA:113,0 +DA:116,6 +DA:123,6 +DA:125,0 +DA:126,0 +DA:133,6 +DA:134,0 +DA:135,0 +DA:136,0 +DA:137,0 +DA:138,0 +DA:141,0 +DA:144,6 +DA:145,0 +DA:152,0 +DA:155,6 +LF:50 +LH:18 +BRDA:78,0,0,0 +BRDA:78,0,1,0 +BRDA:80,1,0,0 +BRDA:80,1,1,0 +BRDA:82,2,0,0 +BRDA:82,2,1,0 +BRDA:94,3,0,0 +BRDA:94,3,1,0 +BRDA:97,4,0,0 +BRDA:97,4,1,0 +BRDA:100,5,0,0 +BRDA:100,5,1,0 +BRDA:102,6,0,0 +BRDA:102,6,1,0 +BRDA:109,7,0,0 +BRDA:109,7,1,0 +BRDA:136,8,0,0 +BRDA:136,8,1,0 +BRDA:141,9,0,0 +BRDA:141,9,1,0 +BRF:20 +BRH:0 +end_of_record +TN: +SF:/home/lalis/git/p5.js-web-editor/server/utils/createApplicationErrorClass.js +FN:6,(anonymous_0) +FN:25,createApplicationErrorClass +FN:27,(anonymous_2) +FNF:3 +FNH:3 +FNDA:13,(anonymous_0) +FNDA:8,createApplicationErrorClass +FNDA:13,(anonymous_2) +DA:7,13 +DA:8,13 +DA:9,13 +DA:11,13 +DA:12,13 +DA:13,13 +DA:26,8 +DA:28,13 +DA:30,13 +LF:9 +LH:9 +BRDA:6,0,0,11 +BRDA:8,1,0,13 +BRDA:8,1,1,0 +BRF:3 +BRH:2 +end_of_record +TN: +SF:/home/lalis/git/p5.js-web-editor/server/utils/createId.js +FN:6,createId +FNF:1 +FNH:1 +FNDA:10,createId +DA:7,10 +LF:1 +LH:1 +BRF:0 +BRH:0 +end_of_record