-
Notifications
You must be signed in to change notification settings - Fork 998
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fixes #38242 replace clipboard copy with pf5 #10457
base: develop
Are you sure you want to change the base?
Fixes #38242 replace clipboard copy with pf5 #10457
Conversation
<% if @host.operatingsystem && @host.initial_configuration_template %> | ||
<div style="max-width: 600px"> | ||
<%= _('For initial configuration of the host run this command:') %> | ||
<%= react_component('ClipboardCopy', { text: "curl #{@host.registration_url} | bash", | ||
textareaProps: { readOnly: true, rows: '1', className: 'host-init-conf-textarea'}}) | ||
<%= react_component('ClipboardCopy', { text: "curl #{@host.registration_url} | bash" , textareaProps: {className: 'host-init-conf-textarea'}}) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should pass readonly:true
@@ -20,3 +20,11 @@ | |||
} | |||
} | |||
} | |||
|
|||
.pf-c-clipboard-copy.pf-m-inline{ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please add a classname to the PF component and use it for the css to prevent this css effecting other clipboardCopies
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Or, remove the css and change the variant from inline to a normal type, that also looks fine to me. otherwise, we use pf variables for numbers and colors: https://v5-archive.patternfly.org/developer-resources/global-css-variables
variant={PFClipboardCopyVariant.expansion} | ||
isExpanded | ||
isReadOnly={textareaProps.readOnly ?? false} | ||
className={textareaProps.className ?? ''} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please use null instead of ''
No description provided.