\documentclass[10pt]{beamer}
\definecolor{beige}{RGB}{227,244,227}
\definecolor{mediumseagreen}{RGB}{84,180,73}
\usepackage[most]{tcolorbox}
\newtcolorbox{tipbox}{
enhanced,
fonttitle=\sffamily\bfseries,
colbacktitle=beige,
coltitle=mediumseagreen,
title=TIP,
colbacktitle=beige,
title code={
\path[draw=mediumseagreen,solid,line width=0.75mm]
([xshift=5mm]title.south west) -- ([xshift=-5mm]title.south east);
},
boxrule=0pt,frame hidden,
borderline west={4pt}{0pt}{mediumseagreen},
colback=beige,
}
\begin{document}
%
\begin{frame}
\begin{tipbox}
https://www.siyavula.com/read/science/grade-10/classification-of-matter/02-classification-of-matter-04
\end{tipbox}
\end{frame}
\end{document}
答案1
在标题的代码中添加填充很容易。
\documentclass[10pt]{beamer}
\definecolor{beige}{RGB}{227,244,227}
\definecolor{mediumseagreen}{RGB}{84,180,73}
\usepackage[most]{tcolorbox}
\newtcolorbox{tipbox}{
enhanced,
fonttitle=\sffamily\bfseries,
coltitle=mediumseagreen,
title=TIP,
title code={
\path[fill=beige] (title.south west) rectangle (title.north east);
\path[draw=mediumseagreen,solid,line width=0.75mm]
([xshift=5mm]title.south west) -- ([xshift=-5mm]title.south east);
},
boxrule=0pt,frame hidden,
borderline west={4pt}{0pt}{mediumseagreen},
colback=beige,
colbacktitle=beige,
}
\begin{document}
%
\begin{frame}
\begin{tipbox}
https://www.siyavula.com/read/science/grade-10/classification-of-matter/02-classification-of-matter-04
\end{tipbox}
\end{frame}
\end{document}