
    Q3j                          d dl Z ddZy)    Nc                    d}d}t        |       }| d|dk(  rdnd }| D cg c]'  }|j                  t        j                  |            ) }}|j                  |t        j                  |      dj	                  |      	      S c c}w )
zGenerate HTML representation of feature names.

    Creates a collapsible HTML details element containing a table of feature
    names with a summary line showing the total count. Includes a copy-to-clipboard
    button for all feature names.
    a<  
        <div class="features {is_fitted_css_class}">
          <details>
            <summary>
              <div class="arrow"></div>
              <div>{total_features_line}</div>
              <div class="image-container" title="Copy all output features">
                <i class="copy-paste-icon"
                  onclick="
                  event.stopPropagation();
                  event.preventDefault();
                  copyFeatureNamesToClipboard(this);
                  "
                >
                </i>
              </div>
            </summary>
            <div class="features-container">
                <table class="features-table">
                  <tbody>
                    {rows}
                  </tbody>
                </table>
            </div>
          </details>
        </div>
    z>
        <tr>
          <td>{feature}</td>
        </tr>

        featurefeatures)r    )total_features_lineis_fitted_css_classrows)lenformathtmlescapejoin)r   r
   FEATURES_TABLE_TEMPLATEFEATURES_ROW_TEMPLATEtotal_featuresr	   r   r   s           N/DATA/.local/lib/python3.12/site-packages/sklearn/utils/_repr_html/features.py_features_htmlr      s    8 ]N
!1)<I*MN   G 	$$T[[-A$B 	  #))/ KK(;<WWT] *  	s   ,B)r   )r   r        r   <module>r      s    6r   