I'm stuck trying to verify the proof given in the text. There are parts of the hypothesis and proof that have nothing to do with where I'm stuck, so in the interests of brevity, I'll give only the part I'm having trouble with. We are given $M$, an immersed submanifold with or without boundary in $\mathbb{R}^n$, and $D$, a smooth rank-$k$ subbundle of $T\mathbb{R}^n|_M$. The proof begins as follows:
Let $p\in M$ be arbitrary, and let $(X_1,\dots,X_k)$ be a smooth local frame for $D$ over some neighborhood $V$ of $p$ in $M$. Because immersed submanifolds are locally embedded, by shrinking $V$ if necessary, we may assume that it is a single slice in some coordinate ball or half-ball $U\subseteq\mathbb{R}^n$. Since $V$ is closed in $U$, Proposition 8.11(c) shows that we can complete $(X_1,\dots,X_k)$ to a smooth local frame $(\tilde{X}_1,\dots,\tilde{X}_n)$ for $T\mathbb{R}^n$ over $U$, ...
My problem lies wholly within the above three sentences. The first sentence is fine. The second sentence starts out fine, but I don't think there is such a thing as a coordinate half-ball in $\mathbb{R}^n$ since $\mathbb{R}^n$ has empty boundary. (Please correct me if I'm wrong here.) So I am going to assume that Professor Lee meant to say "assume that it is a single slice or half-slice of some coordinate ball $U\subseteq\mathbb{R}^n$." With that change (which doesn't solve my problem), I am OK with the second sentence and with $V$ being closed in $U$.
Now Proposition 8.11(c) applies to smooth vector fields along a closed subset $V\subseteq U$. For my question, I only need to talk about one of the $X_i$, so let me just call it $X$. I have no problem composing $X$ with smooth maps and restricting codomains so that, I can consider $X$ to be a smooth vector field $X\colon V\to TU$ over $V$. Recall that $V$ is a neighborhood in $M$ and as such has a smooth structure of manifold with (possibly empty) boundary derived from that of $M$. Now let me quote the definition of a smooth vector field along a subset (I've changed the names of the variables to match the present situation):
If $U$ is a smooth manifold with or without boundary and $V\subseteq U$ is an arbitrary subset, a vector field along $V$ is a continuous map $X\colon V\to TU$ satisfying $\pi\circ X=\mathrm{Id}_V$. We call it a smooth vector field along $V$ if for each $q\in V$, there is a neighborhood $W$ of $q$ in $U$ and a smooth vector field $\tilde{X}$ on $W$ that agrees with $X$ on $W\cap V$.
My problem is that given $q\in V$, I haven't been able to find a neighborhood $W$ of $q$ in $U$ and an associated smooth vector field $\tilde{X}$ on $W$ such that $X|_{W\cap V}=\tilde{X}|_{W\cap V}$. I've got $(U,\phi)$, a smooth chart centered at $p$ for $\mathbb{R}^n$, with $\phi(U)$ being the open cube of side $r$ centered at $0_{\mathbb{R}^n}$ and with $\phi(V)=\phi(U)\cap(Z^m\times\{0_{\mathbb{R}^{n-m}}\})$ where $m=\mathrm{dim}\,M$, and $Z=\mathbb{H}$ if $p\in\partial M$ and $Z=\mathbb{R}$ otherwise.
I think I can make things work if $p$ is not a boundary point of $M$ as follows: Let $F\colon\mathbb{R}^n\to\mathbb{R}^n$ be defined by $$F(x_1,\dots,x_m,x_{m+1},\dots,x_n)=(x_1,\dots,x_m,0,\dots,0).$$ Then $F$ is smooth, and when applying $F$ to $\phi(U)$, it produces $\phi(U)\cap(\mathbb{R}^m\times\{0_{\mathbb{R}^{n-m}}\})=\phi(V)$. Thus $\tilde{X}=X\circ\phi^{-1}\circ F\circ\phi\colon U\to TU$ is smooth and equals $X$ on $V$. [EDIT: As pointed out by Tob Ernack, this may be smooth, and may be an extension, but it is not a section and therefore not a solution for the empty boundary case. So I retract the statement that I know how to make it work at an interior point.]
But this won't work when $p\in\partial M$ since then $Z=\mathbb{H}$ and $F(\phi(U))=\phi(U)\cap(\mathbb{R}^m\times\{0_{\mathbb{R}^{n-m}}\})$ which is not equal to $\phi(V)=\phi(U)\cap(\mathbb{H}^m\times\{0_{\mathbb{R}^{n-m}}\})$ and therefore cannot be composed with $X\circ\phi^{-1}$.
So, my question is, how do I show $X$ is a smooth vector field along $V$, when $p\in\partial M$?