Skip to content

Commit

Permalink
Merge pull request #5 from bbsaclay/master
Browse files Browse the repository at this point in the history
v0.4.9
  • Loading branch information
bbsaclay authored Nov 15, 2021
2 parents d9ba8f5 + 44f4dfb commit 486f435
Show file tree
Hide file tree
Showing 13 changed files with 202 additions and 205 deletions.
3 changes: 1 addition & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,7 @@ COPY server server
COPY .logo-ascii .logo-ascii

# Build frontend and install backend dependencies
RUN npm run installApp && npm run buildApp && npm install \
&& rm -rf src frontend
RUN npm i && cd frontend/ && npm i && npm run build && rm -rf src frontend && cd ..

EXPOSE 3000

Expand Down
24 changes: 12 additions & 12 deletions frontend/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "pixano-app-frontend",
"version": "0.4.7",
"version": "0.4.9",
"description": "This is a Pixano app.",
"scripts": {
"copyindex": "shx cp src/index.html ../build",
Expand All @@ -23,11 +23,11 @@
"webpack-cli": "^3.3.10"
},
"dependencies": {
"@babel/core": "^7.7.7",
"@babel/plugin-transform-runtime": "^7.7.6",
"@babel/core": "^7.16.0",
"@babel/plugin-transform-runtime": "^7.16.0",
"@babel/polyfill": "^7.7.0",
"@babel/preset-env": "^7.7.7",
"@babel/runtime": "^7.7.7",
"@babel/preset-env": "^7.16.0",
"@babel/runtime": "^7.16.0",
"@material/mwc-button": "0.19.1",
"@material/mwc-checkbox": "0.19.1",
"@material/mwc-circular-progress-four-color": "0.19.1",
Expand All @@ -49,13 +49,13 @@
"@material/mwc-tab-bar": "0.19.1",
"@material/mwc-textarea": "0.19.1",
"@material/mwc-textfield": "0.19.1",
"@pixano/ai": "0.5.17",
"@pixano/core": "0.5.17",
"@pixano/graphics-2d": "0.5.17",
"@pixano/graphics-3d": "0.5.17",
"@pixano/ai": "0.6.0",
"@pixano/core": "0.6.0",
"@pixano/graphics-2d": "0.6.0",
"@pixano/graphics-3d": "0.6.0",
"@trystan2k/fleshy-jsoneditor": "3.0.0",
"@webcomponents/webcomponentsjs": "^2.4.0",
"babel-loader": "^8.0.6",
"babel-loader": "^8.2.3",
"copy-webpack-plugin": "^5.1.1",
"css-loader": "^3.4.0",
"file-loader": "^5.0.2",
Expand All @@ -65,9 +65,9 @@
"material-design-icons": "^3.0.1",
"node-sass": "^4.13.0",
"pwa-helpers": "^0.9.1",
"redux": "^4.0.4",
"redux": "^4.1.2",
"redux-devtools-extension": "^2.13.8",
"redux-thunk": "^2.3.0",
"redux-thunk": "^2.4.0",
"redux-undo": "^1.0.0",
"sass-loader": "^8.0.0",
"source-map-loader": "^0.2.4",
Expand Down
18 changes: 8 additions & 10 deletions frontend/src/helpers/attribute-picker.js
Original file line number Diff line number Diff line change
Expand Up @@ -112,6 +112,14 @@ export class AttributePicker extends LitElement {
}

static get properties () {
/**
* showDetail: Boolean, rendering mode for the selected category (showing all attributes or only the category)
* shortcuts : Array of strings, contains the list of all applicable keyboard shortcuts
* schema: shema for this annotation (i.e. category and attributes available for each category in this annotation)
* value: {category, options }, contains the value of the current category and its options (i.e. attributes available for this category)
* numDone: Number, only used for keypoints-box
* numTotal: Number, only used for keypoints-box
*/
return {
showDetail: { type: Boolean },
shortcuts: { type: Array },
Expand Down Expand Up @@ -400,16 +408,6 @@ export class AttributePicker extends LitElement {
${this.renderSimple}
`;
}
// render(){
// return html`
// ${this.shortcutsDialog}
// <mwc-icon-button class="shortcut" icon="keyboard" @click=${this.openShortcuts}></mwc-icon-button>
// ${this.renderDetail}
// ${this.renderSimple}
// <div id="todo2">keypoints faits ${this.numDone} / ${this.numTotal}</div>
// `;
// }

}

customElements.define('attribute-picker', AttributePicker);
4 changes: 2 additions & 2 deletions frontend/src/plugins/keypoints-box.js
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ export class PluginKeypointsBox extends TemplatePluginInstance {
freeBoxes.shift();
this.attributePicker.numDone = this.attributePicker.numTotal - freeBoxes.length;
store.dispatch(createAnnotation(newAnnotation));
this.element.shapes = freeBoxes.length ? [{...freeBoxes[0], color: this._colorFor(freeBoxes[0].categoryName) }] : [];
this.element.shapes = freeBoxes.length ? [{...freeBoxes[0], color: this._colorFor(freeBoxes[0].category) }] : [];
} else {
this.element.shapes = [];
}
Expand Down Expand Up @@ -138,7 +138,7 @@ export class PluginKeypointsBox extends TemplatePluginInstance {
.filter((r) => !ids.includes(r.id));
if (freeBoxes.length) {

this.element.shapes = [{...freeBoxes[0], color: this._colorFor(freeBoxes[0].categoryName) }];
this.element.shapes = [{...freeBoxes[0], color: this._colorFor(freeBoxes[0].category) }];
}
}

Expand Down
Loading

0 comments on commit 486f435

Please sign in to comment.