mirror of
https://github.com/chrisnov-it/quantumbotx.git
synced 2026-07-29 03:37:45 +00:00
78737b6835
- Update `.gitignore` to include `lab/` for backtesting and raw data. - Refactor `app.py` to improve error handling and logging. - Remove deprecated files: `core/bot_logic.py`, `core/bots/base_bot.py`, `core/bots/manager.py`, `core/db/database.py`, `core/routes/api_analysis.py`, `core/routes/api_bots_analysis.py`, `core/strategies/logic_ma.py`, `core/strategies/logic_rsi.py`. - Modify multiple files to enhance bot management, routing, and strategy handling. - Update JavaScript and HTML templates for better UI and functionality.
48 lines
1.0 KiB
JavaScript
48 lines
1.0 KiB
JavaScript
import {
|
|
Semicolon,
|
|
LeftCurlyBracket
|
|
} from '../../tokenizer/index.js';
|
|
|
|
export const name = 'AtrulePrelude';
|
|
export const walkContext = 'atrulePrelude';
|
|
export const structure = {
|
|
children: [[]]
|
|
};
|
|
|
|
export function parse(name) {
|
|
let children = null;
|
|
|
|
if (name !== null) {
|
|
name = name.toLowerCase();
|
|
}
|
|
|
|
this.skipSC();
|
|
|
|
if (hasOwnProperty.call(this.atrule, name) &&
|
|
typeof this.atrule[name].prelude === 'function') {
|
|
// custom consumer
|
|
children = this.atrule[name].prelude.call(this);
|
|
} else {
|
|
// default consumer
|
|
children = this.readSequence(this.scope.AtrulePrelude);
|
|
}
|
|
|
|
this.skipSC();
|
|
|
|
if (this.eof !== true &&
|
|
this.tokenType !== LeftCurlyBracket &&
|
|
this.tokenType !== Semicolon) {
|
|
this.error('Semicolon or block is expected');
|
|
}
|
|
|
|
return {
|
|
type: 'AtrulePrelude',
|
|
loc: this.getLocationFromList(children),
|
|
children
|
|
};
|
|
}
|
|
|
|
export function generate(node) {
|
|
this.children(node);
|
|
}
|