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: composer.rb
    path of file: ./repos/discourse/spec/system/page_objects/components
    
    the code of the file until where you have to start completion: # frozen_string_literal: true

module PageObjects
  module Components
    class Composer < PageObjects::Components::Base
      COMPOSER_ID = "#reply-control"
      AUTOCOMPLETE_MENU = ".autocomplete.ac-emoji"

      def opened?
        page.has_css?("#{COMPOSER_ID}.open")
      end

      def closed?
        page.has_css?("#{COMPOSER_ID}.closed", visible: :all)
      end

      def open_composer_actions
        find(".composer-action-title .btn").click
        self
      end

      def click_toolbar_button(button_class)
        find(".d-editor-button-bar button.#{button_class}").click
        self
      end

      def fill_title(title)
        find("#{COMPOSER_ID} #reply-title").fill_in(with: title)
        self
      end

      def fill_content(content)
        composer_input.fill_in(with: content)
        self
      end

      def append_content(content)
        current_content = composer_input.value
        composer_input.set(current_content + content)
        self
      end

      def fill_form_template_field(field, content)
        form_template_field(field).fill_in(with: content)
        self
      end

      def type_c
    
      def move_cursor_after(text)
        execute_script(<<~JS, text)
          const text = arguments[0];
          const composer = document.querySelector("#{COMPOSER_ID} .d-editor-input");
          const index = composer.value.indexOf(text);
          const position = index + text.length;

          composer.setSelectionRange(position, position);
        JS
      end

      def select_all
        execute_script(<<~JS, text)
          const composer = document.querySelector("#{COMPOSER_ID} .d-editor-input");
          composer.setSelectionRange(0, composer.value.length);
        JS
      end

      def submit
        find("#{COMPOSER_ID} .save-or-cancel .create").click
      end

      def close
        find("#{COMPOSER_ID} .save-or-cancel .cancel").click
      end

      def has_no_in_progress_uploads?
        find("#{COMPOSER_ID}").has_no_css?("#file-uploading")
      end

      def has_in_progress_uploads?
        find("#{COMPOSER_ID}").has_css?("#file-uploading")
      end

      def select_pm_user(username)
        select_kit = PageObjects::Components::SelectKit.new("#private-message-users")
        select_kit.expand
        select_kit.search(username)
        select_kit.select_row_by_value(username)
        select_kit.collapse
      end

      private

      def emoji_preview_selector(emoji)
        ".d-editor-preview .emoji[title=':#{emoji}:']"
      end
    end
  end