You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: audio_recorder_renderer.rb
    path of file: ./repos/chaskiq/app/services/dante
    
    the code of the file until where you have to start completion: class Dante::AudioRecorderRenderer
  def initialize(block_key:, data:, domain: nil)
    @block_key = block_key
    @data = data
    @domain = domain
  end

  def render
    url, caption = @data.values_at(:url, :caption)
    audio_url = get_url(url, @domain)

    figure = <<~HTML
      <figure id="#{@block_key}" class="graf graf--figure">
        <div>
          <div>
            #{url && "<audio src=\"#{audio_url}\" controls></audio>"}
          </div>
        </div>
        #{caption_html(caption)}
      </figure>
    HTML

    figure.strip
  end

  private

  def get_url(url, domain)
    domain ? "#{domain}#{url}" : url
  end

  def caption_html(caption)
    return "" unless caption && caption != "type a caption (optional)"

    <<~HTML
     
    
  def initialize(block_key:, data:, domain: nil)
    @block_key = block_key
    @data = data
    @domain = domain
  end

  def render
    url, caption = @data.values_at(:url, :caption)
    audio_url = get_url(url, @domain)

    figure = <<~HTML
      <figure id="#{@block_key}" class="graf graf--figure">
        <div>
          <div>
            #{url && "<audio src=\"#{audio_url}\" controls></audio>"}
          </div>
        </div>
        #{caption_html(caption)}
      </figure>
    HTML

    figure.strip
  end

  private

  def get_url(url, domain)
    domain ? "#{domain}#{url}" : url
  end

  def caption_html(caption)
    return "" unless caption && caption != "type a caption (optional)"

    <<~HTML
      <figcaption class="imageCaption">
        <span>
          <span data-text="true">#{caption}</span>
        </span>
      </figcaption>
    HTML
  end
end