-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.eslintcache
1 lines (1 loc) · 10.9 KB
/
.eslintcache
1
[{"C:\\Users\\yonat\\Desktop\\Js study\\REACT\\projects\\loop-machine\\src\\index.js":"1","C:\\Users\\yonat\\Desktop\\Js study\\REACT\\projects\\loop-machine\\src\\components\\App.js":"2","C:\\Users\\yonat\\Desktop\\Js study\\REACT\\projects\\loop-machine\\src\\components\\Pad.js":"3","C:\\Users\\yonat\\Desktop\\Js study\\REACT\\projects\\loop-machine\\src\\reducers\\index.js":"4","C:\\Users\\yonat\\Desktop\\Js study\\REACT\\projects\\loop-machine\\src\\reducers\\padsReducer.js":"5","C:\\Users\\yonat\\Desktop\\Js study\\REACT\\projects\\loop-machine\\src\\actions\\types.js":"6","C:\\Users\\yonat\\Desktop\\Js study\\REACT\\projects\\loop-machine\\src\\actions\\index.js":"7","C:\\Users\\yonat\\Desktop\\Js study\\REACT\\projects\\loop-machine\\src\\components\\Board.js":"8","C:\\Users\\yonat\\Desktop\\Js study\\REACT\\projects\\loop-machine\\src\\loops\\index.js":"9","C:\\Users\\yonat\\Desktop\\Js study\\REACT\\projects\\loop-machine\\src\\reducers\\loopMachineReducer.js":"10","C:\\Users\\yonat\\Desktop\\Js study\\REACT\\projects\\loop-machine\\src\\assets\\icons\\index.js":"11","C:\\Users\\yonat\\Desktop\\Js study\\REACT\\projects\\loop-machine\\src\\components\\Recorder.js":"12"},{"size":563,"mtime":1608987568081,"results":"13","hashOfConfig":"14"},{"size":191,"mtime":1609320547176,"results":"15","hashOfConfig":"14"},{"size":2499,"mtime":1609317363519,"results":"16","hashOfConfig":"14"},{"size":235,"mtime":1609152349745,"results":"17","hashOfConfig":"14"},{"size":745,"mtime":1609317279166,"results":"18","hashOfConfig":"14"},{"size":202,"mtime":1609317404796,"results":"19","hashOfConfig":"14"},{"size":606,"mtime":1609317397785,"results":"20","hashOfConfig":"14"},{"size":1044,"mtime":1609318938287,"results":"21","hashOfConfig":"14"},{"size":479,"mtime":1609081042517,"results":"22","hashOfConfig":"14"},{"size":1195,"mtime":1609317566557,"results":"23","hashOfConfig":"14"},{"size":406,"mtime":1609185175645,"results":"24","hashOfConfig":"14"},{"size":2157,"mtime":1609322465859,"results":"25","hashOfConfig":"14"},{"filePath":"26","messages":"27","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0,"usedDeprecatedRules":"28"},"1dd8rbn",{"filePath":"29","messages":"30","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"31","messages":"32","errorCount":0,"warningCount":2,"fixableErrorCount":0,"fixableWarningCount":0,"source":"33","usedDeprecatedRules":"28"},{"filePath":"34","messages":"35","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0,"usedDeprecatedRules":"28"},{"filePath":"36","messages":"37","errorCount":0,"warningCount":1,"fixableErrorCount":0,"fixableWarningCount":0,"source":"38","usedDeprecatedRules":"28"},{"filePath":"39","messages":"40","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0,"usedDeprecatedRules":"28"},{"filePath":"41","messages":"42","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0,"usedDeprecatedRules":"28"},{"filePath":"43","messages":"44","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"45","messages":"46","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0,"usedDeprecatedRules":"28"},{"filePath":"47","messages":"48","errorCount":0,"warningCount":4,"fixableErrorCount":0,"fixableWarningCount":0,"source":"49","usedDeprecatedRules":"28"},{"filePath":"50","messages":"51","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0,"usedDeprecatedRules":"28"},{"filePath":"52","messages":"53","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},"C:\\Users\\yonat\\Desktop\\Js study\\REACT\\projects\\loop-machine\\src\\index.js",[],["54","55"],"C:\\Users\\yonat\\Desktop\\Js study\\REACT\\projects\\loop-machine\\src\\components\\App.js",[],"C:\\Users\\yonat\\Desktop\\Js study\\REACT\\projects\\loop-machine\\src\\components\\Pad.js",["56","57"],"import React, { Component } from \"react\";\r\nimport { connect } from \"react-redux\";\r\nimport {\r\n updatePadBeatsPerSec,\r\n addActivePadCount,\r\n subActivePadCount,\r\n} from \"../actions\";\r\nimport { Howl, Howler } from \"howler\";\r\n\r\nexport class Pad extends Component {\r\n constructor(props) {\r\n super(props);\r\n const audio = { sound: props.soundTrack };\r\n const src = audio.sound;\r\n const sound = new Howl({\r\n src,\r\n loop: true,\r\n sprite: { start: null },\r\n });\r\n this.state = {\r\n sound,\r\n isOn: false,\r\n };\r\n }\r\n componentDidMount() {\r\n //After mp3 is loaded the component update his beats per sec.\r\n this.state.sound.on(\"load\", () =>\r\n this.props.updatePadBeatsPerSec(\r\n this.props.padId,\r\n 120 / this.state.sound.duration() / this.state.sound.duration()\r\n )\r\n );\r\n }\r\n\r\n soundPlay() {\r\n //calculate the starting point of the track(depends the other track are on)\r\n let startingPoint =\r\n (((this.props.machineState.totalBeatsPass /\r\n this.props.padState.beatsPerSec) *\r\n 1000) %\r\n this.state.sound.duration()) *\r\n 1000;\r\n //add active pad to App state\r\n this.props.addActivePadCount(this.props.padState.beatsPerSec);\r\n const track = this.state.sound;\r\n //Setting the starting point of the mp3.\r\n track._sprite.start = [startingPoint];\r\n\r\n track.play(\"start\");\r\n this.setState({ isOn: true });\r\n }\r\n\r\n soundStop() {\r\n this.state.sound.stop();\r\n this.setState({ isOn: false });\r\n this.props.subActivePadCount();\r\n }\r\n render() {\r\n Howler.volume(1.0);\r\n const padState = this.props.padState.state;\r\n\r\n return (\r\n <div\r\n className=\"pad\"\r\n style={{\r\n background: this.state.isOn\r\n ? \"radial-gradient(#74e18c, #14a15b)\"\r\n : \"radial-gradient(#e18174, #d15746)\",\r\n }}\r\n onClick={\r\n this.state.isOn ? () => this.soundStop() : () => this.soundPlay()\r\n }\r\n >\r\n <img src={this.props.icon} />\r\n <i className={` ${this.state.isOn ? \"stop\" : \"play\"} icon large`}></i>\r\n </div>\r\n );\r\n }\r\n}\r\n\r\nconst mapStateToProps = (state, ownProps) => {\r\n return {\r\n padState: state.pads[ownProps.padId],\r\n machineState: state.machine,\r\n };\r\n};\r\n\r\n// const mapDispatchToProps = () => {\r\n// return { pressOff, pressOn };\r\n// };\r\n\r\nexport default connect(mapStateToProps, {\r\n updatePadBeatsPerSec,\r\n addActivePadCount,\r\n subActivePadCount,\r\n})(Pad);\r\n","C:\\Users\\yonat\\Desktop\\Js study\\REACT\\projects\\loop-machine\\src\\reducers\\index.js",[],"C:\\Users\\yonat\\Desktop\\Js study\\REACT\\projects\\loop-machine\\src\\reducers\\padsReducer.js",["58"],"import { UPDATE_PAD_BPM } from \"../actions/types\";\r\n\r\nconst INITIAL_STATE = {\r\n 1: { padId: 1, beatsPerSec: 0 },\r\n 2: { padId: 2, beatsPerSec: 0 },\r\n 3: { padId: 3, beatsPerSec: 0 },\r\n 4: { padId: 4, beatsPerSec: 0 },\r\n 5: { padId: 5, beatsPerSec: 0 },\r\n 6: { padId: 6, beatsPerSec: 0 },\r\n 7: { padId: 7, beatsPerSec: 0 },\r\n 8: { padId: 8, beatsPerSec: 0 },\r\n 9: { padId: 9, beatsPerSec: 0 },\r\n};\r\n\r\nexport default (state = INITIAL_STATE, action) => {\r\n switch (action.type) {\r\n case UPDATE_PAD_BPM:\r\n return {\r\n ...state,\r\n [action.payload.padId]: {\r\n ...state[action.payload.padId],\r\n beatsPerSec: action.payload.beatsPerSec,\r\n },\r\n };\r\n default:\r\n return state;\r\n }\r\n};\r\n","C:\\Users\\yonat\\Desktop\\Js study\\REACT\\projects\\loop-machine\\src\\actions\\types.js",[],"C:\\Users\\yonat\\Desktop\\Js study\\REACT\\projects\\loop-machine\\src\\actions\\index.js",[],"C:\\Users\\yonat\\Desktop\\Js study\\REACT\\projects\\loop-machine\\src\\components\\Board.js",[],"C:\\Users\\yonat\\Desktop\\Js study\\REACT\\projects\\loop-machine\\src\\loops\\index.js",[],"C:\\Users\\yonat\\Desktop\\Js study\\REACT\\projects\\loop-machine\\src\\reducers\\loopMachineReducer.js",["59","60","61","62"],"import {\r\n ADD_ACTIVE_PAD,\r\n SUB_ACTIVE_PAD,\r\n UPDATE_BEAT_STAMP,\r\n} from \"../actions/types\";\r\n\r\nconst INITIAL_STATE = {\r\n currBeatsStamp: 0,\r\n totalBeatsPass: 0,\r\n currOnPads: 0,\r\n};\r\n\r\nexport default (state = INITIAL_STATE, action) => {\r\n switch (action.type) {\r\n //Add one to count of active pads and if it is the first active pad set the beats stamp\r\n case ADD_ACTIVE_PAD:\r\n return {\r\n ...state,\r\n currOnPads: state.currOnPads + 1,\r\n currBeatsStamp:\r\n state.currOnPads == 0 ? action.payload : state.currBeatsStamp,\r\n };\r\n //sub one from count of active pads and if it is the last active pad set the beats stamp to zero.\r\n case SUB_ACTIVE_PAD:\r\n return {\r\n ...state,\r\n currOnPads: state.currOnPads - 1,\r\n currBeatsStamp: state.currOnPads - 1 == 0 ? 0 : state.currBeatsStamp,\r\n };\r\n case UPDATE_BEAT_STAMP:\r\n //update the total beats pass seen the first pad activated\r\n return {\r\n ...state,\r\n totalBeatsPass:\r\n state.currOnPads == 0\r\n ? 0\r\n : state.totalBeatsPass + state.currBeatsStamp,\r\n };\r\n\r\n default:\r\n return state;\r\n }\r\n};\r\n","C:\\Users\\yonat\\Desktop\\Js study\\REACT\\projects\\loop-machine\\src\\assets\\icons\\index.js",[],"C:\\Users\\yonat\\Desktop\\Js study\\REACT\\projects\\loop-machine\\src\\components\\Recorder.js",[],{"ruleId":"63","replacedBy":"64"},{"ruleId":"65","replacedBy":"66"},{"ruleId":"67","severity":1,"message":"68","line":60,"column":11,"nodeType":"69","messageId":"70","endLine":60,"endColumn":19},{"ruleId":"71","severity":1,"message":"72","line":74,"column":9,"nodeType":"73","endLine":74,"endColumn":38},{"ruleId":"74","severity":1,"message":"75","line":15,"column":1,"nodeType":"76","endLine":28,"endColumn":3},{"ruleId":"74","severity":1,"message":"75","line":13,"column":1,"nodeType":"76","endLine":43,"endColumn":3},{"ruleId":"77","severity":1,"message":"78","line":21,"column":28,"nodeType":"79","messageId":"80","endLine":21,"endColumn":30},{"ruleId":"77","severity":1,"message":"78","line":28,"column":46,"nodeType":"79","messageId":"80","endLine":28,"endColumn":48},{"ruleId":"77","severity":1,"message":"78","line":35,"column":28,"nodeType":"79","messageId":"80","endLine":35,"endColumn":30},"no-native-reassign",["81"],"no-negated-in-lhs",["82"],"no-unused-vars","'padState' is assigned a value but never used.","Identifier","unusedVar","jsx-a11y/alt-text","img elements must have an alt prop, either with meaningful text, or an empty string for decorative images.","JSXOpeningElement","import/no-anonymous-default-export","Assign arrow function to a variable before exporting as module default","ExportDefaultDeclaration","eqeqeq","Expected '===' and instead saw '=='.","BinaryExpression","unexpected","no-global-assign","no-unsafe-negation"]