Display indicator only
Hello,
Is it possible to limit the toggle labels so that they are displayed on the forms but NOT on the index. Currently I have the following:
Toggle::make('Status', 'status')
->showLabels()
->trueLabel('Published')
->falseLabel('Draft')
->trueValue('published')
->falseValue('draft'),
This works well and the labels are visible on the toggle form:

However due to limited space on the resource index I would like to remove the label (red boxes) so that only the indicator is shown:

I have been able to achieve this when I remove labels all together but would prefer not to do this.
Thank you for the package and your help, the package is really useful.
Hi @atmediauk , This should be possible - it just needs a extra method to be added such as ->hideLabelOnIndex()
This would be a boolean that is also checked as to whether to show a label or not. IndexField.vue needs a bit of extra logic to check for this.
If you could PR this then I can bring it in :) Alas right now I might not get a chance till August to implement this myself.
D
I am currently working on the new version for the latest upcoming Nova version (v4) which will use Vue 3; and I will be implementing Headless UI's toggle. https://headlessui.dev/vue/switch
This is something I will look into including in the package.