Skip to content
This repository has been archived by the owner on Jul 3, 2023. It is now read-only.

Commit

Permalink
Changed slider to always display the range of images a token must be …
Browse files Browse the repository at this point in the history
…present on instead of a calculated cardinality
  • Loading branch information
dpwrussell committed Jan 25, 2016
1 parent 32c11c8 commit ae4e8a8
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 14 deletions.
8 changes: 1 addition & 7 deletions autotag/src/AutoTagForm.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -93,12 +93,6 @@ export default class AutoTagForm extends React.Component {
token = tokenMap.get(value);
token.increment(tokenType);

// Also, update the maxTokenCardinality if this is higher than the current
// maximum recorded value
if (token.count > this.state.maxTokenCardinality) {
this.state.maxTokenCardinality = token.count;
}

// Otherwise, create the entry and do any token -> tag matching
} else {
token = new Token(value, tokenType);
Expand Down Expand Up @@ -341,7 +335,7 @@ export default class AutoTagForm extends React.Component {
tokenMap: tokenMap,
unmappedTags: unmappedTags,
requiredTokenCardinality: images.size === 1 ? 1 : 2,
maxTokenCardinality: this.state.maxTokenCardinality
maxTokenCardinality: images.size
});

}
Expand Down
8 changes: 1 addition & 7 deletions autotag/static/autotag/js/bundle.js
Original file line number Diff line number Diff line change
Expand Up @@ -19808,12 +19808,6 @@ var autotagform =
token = tokenMap.get(value);
token.increment(tokenType);

// Also, update the maxTokenCardinality if this is higher than the current
// maximum recorded value
if (token.count > this.state.maxTokenCardinality) {
this.state.maxTokenCardinality = token.count;
}

// Otherwise, create the entry and do any token -> tag matching
} else {
token = new _Token2.default(value, tokenType);
Expand Down Expand Up @@ -20031,7 +20025,7 @@ var autotagform =
tokenMap: tokenMap,
unmappedTags: unmappedTags,
requiredTokenCardinality: images.size === 1 ? 1 : 2,
maxTokenCardinality: _this2.state.maxTokenCardinality
maxTokenCardinality: images.size
});
});

Expand Down

0 comments on commit ae4e8a8

Please sign in to comment.