Conditional field within a grid

I have a grid field that contains an entry and text field. I'd like to only show the text field if the entry is blank, on each row (e.g. hide the text field once a user selects an entry).

I'm guessing I would need to be able to check the entry field for the current row, but I'm not sure how to do that.

The closest thing I could find in the docs is looking within an array field, but that's not quite what I'm after. Is this even possible to do on a per-row basis within a grid field?

Here's the relevant part of my blueprint:

handle: tracklist
field:
  fields:
    -
      handle: song
      field:
        type: entries
        display: Song
        collections:
          - songs
    -
      handle: description
      field:
        type: text
        display: Description
        unless:
          song: 'not null'

The song: 'not null' part doesn't work because there's not a top-level field called song. tracklist.song doesn't have any effect, either.

>>>>>>> Unanswered <<<<<<<
3 Replies
2 Followers