You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on May 18, 2022. It is now read-only.
Would you be interested in a PR to allow user customizing other options to ignore other than the ones you established? (links, inputs, etc)
The reason is that I had to integrate https://github.com/dillingham/nova-button and this package does not use either <button> or <a> but a simple <span> with a class nova-button.
I made a version of your packet where I parse the span class and ignore the click listener to, but is hardcoded in my project.
I was thinking about the best way for the user to indicate that other items to ignore: Option 1: using dotenv (https://www.npmjs.com/package/dotenv) we could give the user the option to include. in his .env
I think the Option 1 is a bit strange given that this package does something so simple, I think a better and easy option to solve this problem would be following the default convention for setting up a tool in Nova, for example, we could do something like this:
In NovaServiceProvider.php
/** * Get the tools that should be listed in the Nova sidebar. * * @return array */publicfunctiontools()
{
return [
newClickableTableRow([
'ignoreElements' => [
'.nova-button',
'.other-class',
'#some-id .some-class'
]
])
];
}
And from within the ClickableTableRow we can pass any arbitrary data to the tool.js by calling:
and then we can retrieve this info back in tool.js by calling Nova.config.clickableTableRow
I believe this would be a cleaner solution to accept config options, and also this would open doors for a future feature I am planning to do soon where I need this package not to be applied to certain table resources
So it would be just a matter of including another option on the options array:
Excelente package!
Would you be interested in a PR to allow user customizing other options to ignore other than the ones you established? (links, inputs, etc)
The reason is that I had to integrate https://github.com/dillingham/nova-button and this package does not use either
<button>
or<a>
but a simple<span>
with a class nova-button.I made a version of your packet where I parse the span class and ignore the click listener to, but is hardcoded in my project.
I was thinking about the best way for the user to indicate that other items to ignore:
Option 1: using dotenv (https://www.npmjs.com/package/dotenv) we could give the user the option to include. in his
.env
Option 2: Have the tool inject some meta element into the header, and can the file too.js read it from there?
Option 3: any better ideas?
The text was updated successfully, but these errors were encountered: