I'm currently writing a thesis and would like to format my definitions nicely. This question helped me creating a nice layout for my definitions. The following code
\documentclass{book}
\usepackage[most]{tcolorbox}
\newtcolorbox[auto counter,list inside=defs,number within=section]{definition}[2][]{title={Definition~\thetcbcounter},colback={white!30!yellow},colbacktitle={gray},coltitle=black,#1}
\newcommand{\listofdefinitions}{%
\tcblistof[\section*]{defs}{List of Definitions}
}
\begin{document}
\listofdefinitions
\chapter{Foo}
\section{Foobar}
\begin{definition}[label=latex]{On \LaTeXe}
\LaTeXe is very nice!
\end{definition}
\begin{definition}[label=MWE]{On MWE}
Providing a MWE helps
\end{definition}
\end{document}
What I would like to have, however, is a way to create my own custom definition titles for each definition. I.e. instead of "Definition 1.1.1" and "Definition 1.1.2", I would like to have ""Definition 1.1.1 - My first definition dealing with topic A" and ""Definition 1.1.2 - My second definition dealing with topic B".
Thank you very much for your help.