outl1ne / nova-simple-repeatable

A Laravel Nova simple repeatable rows field.
MIT License
73 stars 44 forks source link

Field don't support show options #16

Closed keizah7 closed 3 years ago

keizah7 commented 3 years ago
            SimpleRepeatable::make(__('Photos'), 'photos', [
                Text::make(__('Link'), 'link')
                    ->rules('required')
                    ->onlyOnForms(),

                Text::make(__('Link'), fn () => '<a href="/admin/resources/cities/4" class="no-underline font-bold dim text-primary">test</a>')
                    ->rules('required')
                    ->asHtml()
                    ->onlyOnDetail(),
            ]),

image

Tarpsvo commented 3 years ago

Hi! What do you mean?

->resolveUsing() seems to work perfectly for me.

keizah7 commented 3 years ago

Can't make field ->asHtml()

Tarpsvo commented 3 years ago

Seems to work perfectly for me. Are you using some field that isn't Text?

keizah7 commented 3 years ago

I was using Text with ->asHtml()

Tarpsvo commented 3 years ago

But even your screenshot shows that the link exists? I'm really confused as to what exactly isn't working. :(