You are here

gutenberg.routing.yml in Gutenberg 8

Same filename and directory in other branches
  1. 8.2 gutenberg.routing.yml

File

gutenberg.routing.yml
View source
  1. gutenberg.media.upload:
  2. path: '/editor/media/upload/{editor}'
  3. defaults:
  4. _controller: '\Drupal\gutenberg\Controller\MediaController::upload'
  5. requirements:
  6. _entity_access: 'editor.use'
  7. _permission: 'gutenberg administer'
  8. _method: 'POST'
  9. gutenberg.media.load:
  10. path: '/editor/media/load/{file}'
  11. defaults:
  12. _controller: '\Drupal\gutenberg\Controller\MediaController::load'
  13. parameters:
  14. file:
  15. type: entity:file
  16. requirements:
  17. _permission: 'gutenberg administer'
  18. _method: 'GET'
  19. gutenberg.media.load_media:
  20. path: '/editor/media/load-media/{media}'
  21. defaults:
  22. _controller: '\Drupal\gutenberg\Controller\MediaController::loadMedia'
  23. requirements:
  24. _permission: 'gutenberg administer'
  25. _method: 'GET'
  26. gutenberg.media.dialog:
  27. path: '/editor/media/dialog'
  28. defaults:
  29. _controller: '\Drupal\gutenberg\Controller\MediaController::dialog'
  30. requirements:
  31. _permission: 'gutenberg administer'
  32. _method: 'GET'
  33. gutenberg.media.render:
  34. path: '/editor/media/render/{media}'
  35. defaults:
  36. _controller: '\Drupal\gutenberg\Controller\MediaController::render'
  37. requirements:
  38. _permission: 'gutenberg administer'
  39. _method: 'GET'
  40. gutenberg.blocks.load:
  41. path: '/editor/blocks/load_by_type/{content_type}'
  42. defaults:
  43. _controller: '\Drupal\gutenberg\Controller\BlocksController::loadByType'
  44. content_type: 'none'
  45. requirements:
  46. _permission: 'gutenberg administer'
  47. _method: 'GET'
  48. gutenberg.blocks.load_single:
  49. path: '/editor/blocks/load/{plugin_id}'
  50. defaults:
  51. _controller: '\Drupal\gutenberg\Controller\BlocksController::loadById'
  52. # parameters:
  53. # block:
  54. # type: entity:block
  55. requirements:
  56. _permission: 'gutenberg administer'
  57. _method: 'GET'
  58. gutenberg.reusable_blocks.create:
  59. path: '/editor/reusable-blocks'
  60. defaults:
  61. _controller: '\Drupal\gutenberg\Controller\ReusableBlocksController::save'
  62. methods: 'POST'
  63. requirements:
  64. _permission: 'gutenberg administer'
  65. gutenberg.reusable_blocks.update:
  66. path: '/editor/reusable-blocks/{block_id}'
  67. defaults:
  68. _controller: '\Drupal\gutenberg\Controller\ReusableBlocksController::save'
  69. methods: 'PUT'
  70. requirements:
  71. _custom_access: '\Drupal\gutenberg\Controller\ReusableBlocksController::access'
  72. gutenberg.reusable_blocks.delete:
  73. path: '/editor/reusable-blocks/{block_id}'
  74. defaults:
  75. _controller: '\Drupal\gutenberg\Controller\ReusableBlocksController::delete'
  76. methods: 'DELETE'
  77. requirements:
  78. _custom_access: '\Drupal\gutenberg\Controller\ReusableBlocksController::access'
  79. gutenberg.reusable_blocks.load:
  80. path: '/editor/reusable-blocks'
  81. defaults:
  82. _controller: '\Drupal\gutenberg\Controller\ReusableBlocksController::load'
  83. methods: 'GET'
  84. requirements:
  85. _permission: 'gutenberg administer'
  86. gutenberg.reusable_blocks.load_single:
  87. path: '/editor/reusable-blocks/{block_id}'
  88. defaults:
  89. _controller: '\Drupal\gutenberg\Controller\ReusableBlocksController::load'
  90. methods: 'GET'
  91. requirements:
  92. _custom_access: '\Drupal\gutenberg\Controller\ReusableBlocksController::access'
  93. gutenberg.oembed:
  94. path: '/editor/oembed'
  95. defaults:
  96. _controller: '\Drupal\gutenberg\Controller\OEmbedProxyUrlController::request'
  97. methods: 'GET'
  98. requirements:
  99. _permission: 'gutenberg administer'
  100. gutenberg.content.search:
  101. path: '/editor/search'
  102. defaults:
  103. _controller: '\Drupal\gutenberg\Controller\SearchController::search'
  104. methods: 'GET'
  105. requirements:
  106. _permission: 'gutenberg administer'
  107. gutenberg.media.search:
  108. path: '/editor/media/search/{type}/{search}'
  109. defaults:
  110. _controller: '\Drupal\gutenberg\Controller\MediaController::search'
  111. requirements:
  112. _permission: 'gutenberg administer'
  113. _method: 'GET'
  114. gutenberg.media.update_data:
  115. path: '/editor/media/update_data/{fid}'
  116. defaults:
  117. _controller: '\Drupal\gutenberg\Controller\MediaController::updateData'
  118. requirements:
  119. _permission: 'gutenberg administer'
  120. _method: 'POST'
  121. gutenberg.media.autocomplete:
  122. path: '/editor/media/autocomplete'
  123. defaults:
  124. _controller: '\Drupal\gutenberg\Controller\MediaController::autocomplete'
  125. requirements:
  126. _permission: 'gutenberg administer'
  127. _method: 'GET'
  128. gutenberg.media_edit_form:
  129. path: '/gutenberg/form/media_edit/{media}'
  130. options:
  131. parameters:
  132. media:
  133. type: entity:media
  134. defaults:
  135. _form: '\Drupal\gutenberg\Form\MediaEditForm'
  136. _title: 'MediaEditForm'
  137. parameters:
  138. file:
  139. type: entity:media
  140. requirements:
  141. _permission: 'gutenberg administer'