diff options
Diffstat (limited to 'app/graphql/types/notes/diff_position_type.rb')
-rw-r--r-- | app/graphql/types/notes/diff_position_type.rb | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/app/graphql/types/notes/diff_position_type.rb b/app/graphql/types/notes/diff_position_type.rb index 9c756d56b97..531bd0edac0 100644 --- a/app/graphql/types/notes/diff_position_type.rb +++ b/app/graphql/types/notes/diff_position_type.rb @@ -12,28 +12,28 @@ module Types field :file_path, GraphQL::Types::String, null: false, description: 'Path of the file that was changed.' - field :old_path, GraphQL::Types::String, null: true, - description: 'Path of the file on the start SHA.' field :new_path, GraphQL::Types::String, null: true, description: 'Path of the file on the HEAD SHA.' + field :old_path, GraphQL::Types::String, null: true, + description: 'Path of the file on the start SHA.' field :position_type, Types::Notes::PositionTypeEnum, null: false, description: 'Type of file the position refers to.' # Fields for text positions - field :old_line, GraphQL::Types::Int, null: true, - description: 'Line on start SHA that was changed.' field :new_line, GraphQL::Types::Int, null: true, description: 'Line on HEAD SHA that was changed.' + field :old_line, GraphQL::Types::Int, null: true, + description: 'Line on start SHA that was changed.' # Fields for image positions + field :height, GraphQL::Types::Int, null: true, + description: 'Total height of the image.' + field :width, GraphQL::Types::Int, null: true, + description: 'Total width of the image.' field :x, GraphQL::Types::Int, null: true, description: 'X position of the note.' field :y, GraphQL::Types::Int, null: true, description: 'Y position of the note.' - field :width, GraphQL::Types::Int, null: true, - description: 'Total width of the image.' - field :height, GraphQL::Types::Int, null: true, - description: 'Total height of the image.' def old_line object.old_line if object.on_text? |