also looking at this
chore(deps): update dependency react to 19.2.7
#2137
222 files
+16350
-1825
Review threads live on the whole diff, not on one commit, so none are shown here - a thread's line means something in the branch's final form, and painting it into an intermediate step would put it on code it is not about.
| @@ -1,4 +1,4 @@ | ||
| 1 | import { defaults } from '../config' | |
| 1 | // import { defaults } from '../config' | |
| 2 | 2 | import { barcodes } from './drivers/index' |
| 3 | 3 | import ErrorHandler from './exceptions/ErrorHandler' |
| 4 | 4 | import { InvalidInputException, NoElementException } from './exceptions/exceptions' |
| @@ -21,7 +21,7 @@ export const barcode = function (element: any, text: any, options: any): any { | ||
| 21 | 21 | // Variables that will be passed through the API calls |
| 22 | 22 | api._renderProperties = getRenderProperties(element) |
| 23 | 23 | api._encodings = [] |
| 24 | api._options = defaults | |
| 24 | api._options = {} | |
| 25 | 25 | api._errorHandler = new ErrorHandler(api) |
| 26 | 26 | |
| 27 | 27 | // If text is set, use the simple syntax (render the barcode directly) |
| @@ -168,7 +168,7 @@ API.prototype.render = function () { | ||
| 168 | 168 | return this |
| 169 | 169 | } |
| 170 | 170 | |
| 171 | API.prototype._defaults = defaults | |
| 171 | API.prototype._defaults = {} | |
| 172 | 172 | |
| 173 | 173 | // Prepares the encodings and calls the renderer |
| 174 | 174 | function render(renderProperties: any, encodings: any[], options: any) { |
| @@ -1,11 +1,12 @@ | ||
| 1 | import { defaults } from '../../config' | |
| 1 | // import { defaults } from '../../config' | |
| 2 | 2 | import optionsFromStrings from './optionsFromStrings' |
| 3 | 3 | |
| 4 | 4 | export function getOptionsFromElement(element: HTMLElement): any { |
| 5 | 5 | let options: { [key: string]: any } = {} |
| 6 | 6 | |
| 7 | for (const property in defaults) { | |
| 8 | if (Object.prototype.hasOwnProperty.call(defaults, property)) { | |
| 7 | for (const property in {}) { | |
| 8 | // for (const property in defaults) { | |
| 9 | if (Object.prototype.hasOwnProperty.call({}, property)) { | |
| 9 | 10 | // jsbarcode-* |
| 10 | 11 | if (element.hasAttribute(`jsbarcode-${property.toLowerCase()}`)) { |
| 11 | 12 | options[property] = element.getAttribute(`jsbarcode-${property.toLowerCase()}`) |