For integer $k\geq 2$, a graph $G$ is called $k$-leaf-connected if $|V(G)|\geq k+1$ and given any subset $S\subseteq V(G)$ with $|S|=k$, $G$ always has a spanning tree $T$ such that $S$ is precisely the set of leaves of $T$. In this paper, the authors present a condition based on the size of $G$ to guarantee that $G$ is $k$-leaf-connected, namely: If $G$ is a connected graph of order ${n\geq k+17}$ and minimum degree $\delta\geq k+1\geq 3$ such that ${|E(G)|\geq{{n-3}\choose{2}}+3k+5}$, then $G$ is $k$-leaf-connected unless $$ C_{n+k-1}(G)\in\{K_k\vee(K_{n-k-2}+K_2),K_3\vee(K_{n-5}+2K_1),K_4\vee (K_{n-7}+3K_1)\}, $$ where $C_{n+k-1}(G)$ denotes the $(n+k-1)$-closure of $G$. This improves results of M.~A.~C.~M. Gurgel and Y. Wakabayashi [J. Combin. Theory Ser. B {\bf 41} (1986), no.~1, 1--16; MR0854599] and G.~Y. Ao et al. [Discrete Appl. Math. {\bf 314} (2022), 17--30; MR4396541] and also extends a result of Y. Xu, M. Zhai and B. Wang [Linear Multilinear Algebra {\bf 70} (2022), no.~21, 6096--6107; MR4568541]. The key approach is showing that an $(n+k-1$)-closed non-$k$-leaf-connected graph must contain a large clique if its size is large enough. As applications, sufficient conditions for a graph to be $k$-leaf-connected in terms of the (signless Laplacian) spectral radius of $G$ or its complement are also presented.