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>
2 lines
1.7 KiB
JavaScript
2 lines
1.7 KiB
JavaScript
var f=Object.create;var c=Object.defineProperty;var g=Object.getOwnPropertyDescriptor;var y=Object.getOwnPropertyNames;var W=Object.getPrototypeOf,R=Object.prototype.hasOwnProperty;var b=(e,n)=>{for(var s in n)c(e,s,{get:n[s],enumerable:!0})},u=(e,n,s,t)=>{if(n&&typeof n=="object"||typeof n=="function")for(let i of y(n))!R.call(e,i)&&i!==s&&c(e,i,{get:()=>n[i],enumerable:!(t=g(n,i))||t.enumerable});return e};var h=(e,n,s)=>(s=e!=null?f(W(e)):{},u(n||!e||!e.__esModule?c(s,"default",{value:e,enumerable:!0}):s,e)),A=e=>u(c({},"__esModule",{value:!0}),e);var m={};b(m,{lint:()=>O,ruleType:()=>F});module.exports=A(m);var U=require("semver"),x=e=>typeof e=="object"&&e.hasOwnProperty("exceptions");var V=(e,n,s)=>{let t=!1,i=[],a=[];for(let d in e[n]){if(x(s)&&s.exceptions.includes(d))continue;e[n][d].startsWith("file:")?(t=!0,i.push(d)):a.push(d)}return{hasFileUrlVersions:t,dependenciesWithFileUrlVersion:i,dependenciesWithoutFileUrlVersion:a}};var o=h(require("chalk")),l=h(require("log-symbols"));var p=class{constructor(n,s,t,i){this.lintId=n,this.severity=s,this.node=t,this.lintMessage=i}toString(){let n=this.severity==="error"?l.default.error:l.default.warning,s=o.default.cyan.bold(this.lintId),t=o.default.magenta.bold(this.node),i=this.severity==="error"?o.default.red.bold(this.lintMessage):o.default.yellow(this.lintMessage);return`${n} ${s} - node: ${t} - ${i}`}};var D="no-file-devDependencies",r="devDependencies",F="optionalObject",O=(e,n,s)=>{let t=V(e,r,s);return e.hasOwnProperty(r)&&t.hasFileUrlVersions?new p(D,n,r,`You are using ${r} via url to local file. Please use ${r} from npm. Invalid ${r} include: ${t.dependenciesWithFileUrlVersion.join(", ")}`):null};0&&(module.exports={lint,ruleType});
|