Uploaded image for project: 'OpenShift Bugs'
  1. OpenShift Bugs
  2. OCPBUGS-59946

Multi-line Code Snippet Not Fully Copied Using Clipboard Button in OpenShift Docs

XMLWordPrintable

    • Quality / Stability / Reliability
    • False
    • Hide

      None

      Show
      None
    • None
    • Important
    • None
    • None
    • None
    • None
    • None
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      Description of problem:

        When using the "copy to clipboard" feature on the Red Hat OpenShift 4.19 documentation page, only the first line of the code block is copied (e.g., echo '{), instead of the entire multi-line code snippet.
      
      
       $ echo '{
          "Version": "2012-10-17",
          "Statement": [
              {
                  "Effect": "Allow",
                  "Principal": "*",
                  "Action": "s3:GetObject",
                  "Resource": "arn:aws:s3:::<bucket_name>/*"  1 
              }
          ]
      }' | envsubst > policy.json

      Version-Release number of selected component (if applicable):

          Documentation for OpenShift Container Platform 4.19  
       

      How reproducible:

      Always    

      Steps to Reproduce:

      Visit the documentation page: https://docs.redhat.com/en/documentation/openshift_container_platform/4.19/html-single/hosted_control_planes/hosted-control-planes-overview#hcp-aws-create-secret-s3_hcp-deploy-aws
      
      
      Scroll to the code block under the section about creating a secret from an S3 policy file
      
      
      Click the "copy to clipboard" icon
      
      
      Paste the copied content into a text editor

      Actual results:

          Only the first line (echo '{) is copied.
      

      Expected results:

          Entire multi-line command is copied.
      

      Additional info:

          This bug affects users trying to copy and run complete setup commands directly, which may lead to misconfigurations or confusion.
      

              ocp-docs-bot OCP DocsBot
              rhn-support-arbhagat Arpit Bhagat
              None
              None
              None
              None
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Created:
                Updated:
                Resolved: