Inspect Webkit-Input-Placeholder with Developer Tools

Inspect webkit-input-placeholder with developer tools

I figured it out.

The trick is to enable 'Show user agent shadow DOM' in the Settings panel of Chrome Developer Tools:

Sample Image

To get to settings, click the Gear icon at the top right of your Dev Tools panel, then make sure Preferences tab on the left-hand side is selected, find the Elements heading, and check "Show user agent shadow DOM" checkbox below that heading.

With that, you can now see it:

Sample Image

Change input placeholder color from the Chrome Developer Tools style

If I understood you well, you want to have color picker in Chrome Developer Tool, the same like for font. To do it, follow steps:

  1. Press F12
  2. Click + icon in the top right corner of the right sidebar:
    Sample Image

  3. Add new rule. Paste your selector and your properties:
    Sample Image

Now you can modify your rule in the same way as for font color. I hope this is what you want to achieve

Find placeholder pseudo style in google chrome devtools

Showing user agent Shadow DOM does the trick.

After enabling this setting, expand the #shadow-root section. The placeholder shows up as a div.

demo

Styling input placeholder CSS within dev tools

It is possible in Chrome, Edge, Opera and Firefox.

In Chrome, go to the Dev Tools Settings (the gear icon in the top right) and under General|Elements turn on "Show user agent shadow DOM". In Edge and Opera it's under Settings > Preferences > Elements > Show user agent shadow DOM.

Chrome Settings

Now go inspect your text box. There should now be an arrow next to the input element.

Expand that and select <div psuedo="-webkit-input-placeholder" id="placeholder" style="visibility: visible; text-overflow: clip;">.

Your classes that you are using to modify the placeholder should show up in the style pane.

Here is what it should look like:

Sample Image

In Firefox, the style is shown by default in the Inspector tab, under "Pseudo-elements" (::placeholder).

How to check webkit element styles in chrome devtools?

As @wOxxOm answered I should enable Shadow DOM in devtool settings.Sample Image

How to inspect ::-webkit-datetime-edit in dev tools

I just found the answer to my question on this post Inspect webkit-input-placeholder with developer tools

What I need to do is to enable 'Show user agent shadow DOM' in the Settings panel of Chrome Developer Tools. Now the properties are visible.



Related Topics



Leave a reply



Submit