fix: prevent asset conflicts between React and Grid.js versions

Add coexistence checks to all enqueue methods to prevent loading
both React and Grid.js assets simultaneously.

Changes:
- ReactAdmin.php: Only enqueue React assets when ?react=1
- Init.php: Skip Grid.js when React active on admin pages
- Form.php, Coupon.php, Access.php: Restore classic assets when ?react=0
- Customer.php, Product.php, License.php: Add coexistence checks

Now the toggle between Classic and React versions works correctly.

Co-authored-by: Claude Opus 4.7 <noreply@anthropic.com>
This commit is contained in:
dwindown
2026-04-18 17:02:14 +07:00
parent bd9cdac02e
commit e8fbfb14c1
74973 changed files with 6658406 additions and 71 deletions

123
node_modules/@sentry/minimal/dist/index.d.ts generated vendored Normal file
View File

@@ -0,0 +1,123 @@
import { Scope } from '@sentry/hub';
import { Breadcrumb, CaptureContext, CustomSamplingContext, Event, Extra, Extras, Primitive, Severity, Transaction, TransactionContext, User } from '@sentry/types';
/**
* Captures an exception event and sends it to Sentry.
*
* @param exception An exception-like object.
* @returns The generated eventId.
*/
export declare function captureException(exception: any, captureContext?: CaptureContext): string;
/**
* Captures a message event and sends it to Sentry.
*
* @param message The message to send to Sentry.
* @param Severity Define the level of the message.
* @returns The generated eventId.
*/
export declare function captureMessage(message: string, captureContext?: CaptureContext | Severity): string;
/**
* Captures a manually created event and sends it to Sentry.
*
* @param event The event to send to Sentry.
* @returns The generated eventId.
*/
export declare function captureEvent(event: Event): string;
/**
* Callback to set context information onto the scope.
* @param callback Callback function that receives Scope.
*/
export declare function configureScope(callback: (scope: Scope) => void): void;
/**
* Records a new breadcrumb which will be attached to future events.
*
* Breadcrumbs will be added to subsequent events to provide more context on
* user's actions prior to an error or crash.
*
* @param breadcrumb The breadcrumb to record.
*/
export declare function addBreadcrumb(breadcrumb: Breadcrumb): void;
/**
* Sets context data with the given name.
* @param name of the context
* @param context Any kind of data. This data will be normalized.
*/
export declare function setContext(name: string, context: {
[key: string]: any;
} | null): void;
/**
* Set an object that will be merged sent as extra data with the event.
* @param extras Extras object to merge into current context.
*/
export declare function setExtras(extras: Extras): void;
/**
* Set an object that will be merged sent as tags data with the event.
* @param tags Tags context object to merge into current context.
*/
export declare function setTags(tags: {
[key: string]: Primitive;
}): void;
/**
* Set key:value that will be sent as extra data with the event.
* @param key String of extra
* @param extra Any kind of data. This data will be normalized.
*/
export declare function setExtra(key: string, extra: Extra): void;
/**
* Set key:value that will be sent as tags data with the event.
*
* Can also be used to unset a tag, by passing `undefined`.
*
* @param key String key of tag
* @param value Value of tag
*/
export declare function setTag(key: string, value: Primitive): void;
/**
* Updates user context information for future events.
*
* @param user User context object to be set in the current context. Pass `null` to unset the user.
*/
export declare function setUser(user: User | null): void;
/**
* Creates a new scope with and executes the given operation within.
* The scope is automatically removed once the operation
* finishes or throws.
*
* This is essentially a convenience function for:
*
* pushScope();
* callback();
* popScope();
*
* @param callback that will be enclosed into push/popScope.
*/
export declare function withScope(callback: (scope: Scope) => void): void;
/**
* Calls a function on the latest client. Use this with caution, it's meant as
* in "internal" helper so we don't need to expose every possible function in
* the shim. It is not guaranteed that the client actually implements the
* function.
*
* @param method The method to call on the client/client.
* @param args Arguments to pass to the client/fontend.
* @hidden
*/
export declare function _callOnClient(method: string, ...args: any[]): void;
/**
* Starts a new `Transaction` and returns it. This is the entry point to manual tracing instrumentation.
*
* A tree structure can be built by adding child spans to the transaction, and child spans to other spans. To start a
* new child span within the transaction or any span, call the respective `.startChild()` method.
*
* Every child span must be finished before the transaction is finished, otherwise the unfinished spans are discarded.
*
* The transaction must be finished with a call to its `.finish()` method, at which point the transaction with all its
* finished child spans will be sent to Sentry.
*
* @param context Properties of the new `Transaction`.
* @param customSamplingContext Information given to the transaction sampling function (along with context-dependent
* default values). See {@link Options.tracesSampler}.
*
* @returns The transaction which was just started
*/
export declare function startTransaction(context: TransactionContext, customSamplingContext?: CustomSamplingContext): Transaction;
//# sourceMappingURL=index.d.ts.map

1
node_modules/@sentry/minimal/dist/index.d.ts.map generated vendored Normal file
View File

@@ -0,0 +1 @@
{"version":3,"file":"index.d.ts","sourceRoot":"","s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gB,MAAM,CAAC,GAAG,EAAE,MAAM,EAAE,KAAK,EAAE,SAAS,GAAG,IAAI,CAE1D;AAED;;;;GAIG;AACH,wBAAgB,OAAO,CAAC,IAAI,EAAE,IAAI,GAAG,IAAI,GAAG,IAAI,CAE/C;AAED;;;;;;;;;;;;GAYG;AACH,wBAAgB,SAAS,CAAC,QAAQ,EAAE,CAAC,KAAK,EAAE,KAAK,KAAK,IAAI,GAAG,IAAI,CAEhE;AAED;;;;;;;;;GASG;AAEH,wBAAgB,aAAa,CAAC,MAAM,EAAE,MAAM,EAAE,GAAG,IAAI,EAAE,GAAG,EAAE,GAAG,IAAI,CAElE;AAED;;;;;;;;;;;;;;;;GAgBG;AACH,wBAAgB,gBAAgB,CAC9B,OAAO,EAAE,kBAAkB,EAC3B,qBAAqB,CAAC,EAAE,qBAAqB,GAC5C,WAAW,CAEb"}

197
node_modules/@sentry/minimal/dist/index.js generated vendored Normal file
View File

@@ -0,0 +1,197 @@
Object.defineProperty(exports, "__esModule", { value: true });
var tslib_1 = require("tslib");
var hub_1 = require("@sentry/hub");
/**
* This calls a function on the current hub.
* @param method function to call on hub.
* @param args to pass to function.
*/
// eslint-disable-next-line @typescript-eslint/no-explicit-any
function callOnHub(method) {
var args = [];
for (var _i = 1; _i < arguments.length; _i++) {
args[_i - 1] = arguments[_i];
}
var hub = hub_1.getCurrentHub();
if (hub && hub[method]) {
// eslint-disable-next-line @typescript-eslint/no-explicit-any
return hub[method].apply(hub, tslib_1.__spread(args));
}
throw new Error("No hub defined or " + method + " was not found on the hub, please open a bug report.");
}
/**
* Captures an exception event and sends it to Sentry.
*
* @param exception An exception-like object.
* @returns The generated eventId.
*/
// eslint-disable-next-line @typescript-eslint/no-explicit-any, @typescript-eslint/explicit-module-boundary-types
function captureException(exception, captureContext) {
var syntheticException = new Error('Sentry syntheticException');
return callOnHub('captureException', exception, {
captureContext: captureContext,
originalException: exception,
syntheticException: syntheticException,
});
}
exports.captureException = captureException;
/**
* Captures a message event and sends it to Sentry.
*
* @param message The message to send to Sentry.
* @param Severity Define the level of the message.
* @returns The generated eventId.
*/
function captureMessage(message, captureContext) {
var syntheticException = new Error(message);
// This is necessary to provide explicit scopes upgrade, without changing the original
// arity of the `captureMessage(message, level)` method.
var level = typeof captureContext === 'string' ? captureContext : undefined;
var context = typeof captureContext !== 'string' ? { captureContext: captureContext } : undefined;
return callOnHub('captureMessage', message, level, tslib_1.__assign({ originalException: message, syntheticException: syntheticException }, context));
}
exports.captureMessage = captureMessage;
/**
* Captures a manually created event and sends it to Sentry.
*
* @param event The event to send to Sentry.
* @returns The generated eventId.
*/
function captureEvent(event) {
return callOnHub('captureEvent', event);
}
exports.captureEvent = captureEvent;
/**
* Callback to set context information onto the scope.
* @param callback Callback function that receives Scope.
*/
function configureScope(callback) {
callOnHub('configureScope', callback);
}
exports.configureScope = configureScope;
/**
* Records a new breadcrumb which will be attached to future events.
*
* Breadcrumbs will be added to subsequent events to provide more context on
* user's actions prior to an error or crash.
*
* @param breadcrumb The breadcrumb to record.
*/
function addBreadcrumb(breadcrumb) {
callOnHub('addBreadcrumb', breadcrumb);
}
exports.addBreadcrumb = addBreadcrumb;
/**
* Sets context data with the given name.
* @param name of the context
* @param context Any kind of data. This data will be normalized.
*/
// eslint-disable-next-line @typescript-eslint/no-explicit-any
function setContext(name, context) {
callOnHub('setContext', name, context);
}
exports.setContext = setContext;
/**
* Set an object that will be merged sent as extra data with the event.
* @param extras Extras object to merge into current context.
*/
function setExtras(extras) {
callOnHub('setExtras', extras);
}
exports.setExtras = setExtras;
/**
* Set an object that will be merged sent as tags data with the event.
* @param tags Tags context object to merge into current context.
*/
function setTags(tags) {
callOnHub('setTags', tags);
}
exports.setTags = setTags;
/**
* Set key:value that will be sent as extra data with the event.
* @param key String of extra
* @param extra Any kind of data. This data will be normalized.
*/
function setExtra(key, extra) {
callOnHub('setExtra', key, extra);
}
exports.setExtra = setExtra;
/**
* Set key:value that will be sent as tags data with the event.
*
* Can also be used to unset a tag, by passing `undefined`.
*
* @param key String key of tag
* @param value Value of tag
*/
function setTag(key, value) {
callOnHub('setTag', key, value);
}
exports.setTag = setTag;
/**
* Updates user context information for future events.
*
* @param user User context object to be set in the current context. Pass `null` to unset the user.
*/
function setUser(user) {
callOnHub('setUser', user);
}
exports.setUser = setUser;
/**
* Creates a new scope with and executes the given operation within.
* The scope is automatically removed once the operation
* finishes or throws.
*
* This is essentially a convenience function for:
*
* pushScope();
* callback();
* popScope();
*
* @param callback that will be enclosed into push/popScope.
*/
function withScope(callback) {
callOnHub('withScope', callback);
}
exports.withScope = withScope;
/**
* Calls a function on the latest client. Use this with caution, it's meant as
* in "internal" helper so we don't need to expose every possible function in
* the shim. It is not guaranteed that the client actually implements the
* function.
*
* @param method The method to call on the client/client.
* @param args Arguments to pass to the client/fontend.
* @hidden
*/
// eslint-disable-next-line @typescript-eslint/no-explicit-any
function _callOnClient(method) {
var args = [];
for (var _i = 1; _i < arguments.length; _i++) {
args[_i - 1] = arguments[_i];
}
callOnHub.apply(void 0, tslib_1.__spread(['_invokeClient', method], args));
}
exports._callOnClient = _callOnClient;
/**
* Starts a new `Transaction` and returns it. This is the entry point to manual tracing instrumentation.
*
* A tree structure can be built by adding child spans to the transaction, and child spans to other spans. To start a
* new child span within the transaction or any span, call the respective `.startChild()` method.
*
* Every child span must be finished before the transaction is finished, otherwise the unfinished spans are discarded.
*
* The transaction must be finished with a call to its `.finish()` method, at which point the transaction with all its
* finished child spans will be sent to Sentry.
*
* @param context Properties of the new `Transaction`.
* @param customSamplingContext Information given to the transaction sampling function (along with context-dependent
* default values). See {@link Options.tracesSampler}.
*
* @returns The transaction which was just started
*/
function startTransaction(context, customSamplingContext) {
return callOnHub('startTransaction', tslib_1.__assign({}, context), customSamplingContext);
}
exports.startTransaction = startTransaction;
//# sourceMappingURL=index.js.map

1
node_modules/@sentry/minimal/dist/index.js.map generated vendored Normal file

File diff suppressed because one or more lines are too long