What is the type of quantity of electric current ? is it vector or scalar? I'm reading David j. Griffiths-Introduction to Electrodynamics
in section $5.1.3$ named by Currents we wrote this
'' Current is actually a vector:
I = $λ$v.
Because the path of the flow is dictated by the shape of the wire, one doesn’t
ordinarily bother to display the direction of I explicitly, but when it comes to
surface and volume currents we cannot afford to be so casual ''
in contrary with Engineering Electromagnetics by William H. Hayt textbook which he wrote this:
'' Current is not a vector, for it is easy to visualize a problem in which a total current I in a conductor of
nonuniform cross section (such as a sphere) may have a different direction at each point of a given
cross section. Current in an exceedingly fine wire, or a filamentar current, is occasionally defined as a
vector, but we usually prefer to be consistent and give the direction to the filament, or path, and not to
the current''
Many questions arise at this point
$1$) What is truly the nature of current? is it vector or scalar quantity? and if it's vector how in KCL we sum the current algebraically not vectorially?
$2$) how can the current be a vector quantity and it's equal to
\begin{gather*} I=\int_{S}^{}\overrightarrow{J} \cdot d\overrightarrow{S} \end{gather*}
which is a dot product how can a dot product produce a vector quantity ?
$3$) and why when dealing with electrical circuits when solving a problem and a current become negative we flip it's direction ?
 A: An often-unstated principle in making physical models of systems is that they are simplifications of reality.  One of the hallmarks of a good model that it is simple enough to understand what you're trying to find out or understand, while at the same time being inclusive enough that it actually gives accurate-enough* results.
What you're struggling with is three different models of current.  These models are conceived for different purposes, by different people.  Each one of these models will help you understand some aspect of physical reality.  I need to descend into opinion, here, because designing models -- and writing textbooks -- is an art, and art is intuitive.
David j. Griffiths is correct for the book he is writing.  He probably should have said "current can be treated as a vector", or perhaps even "current in a wire can be treated as a vector", or even "in a thin wire".  Were I writing such a statement, I'd add "for the purposes of this analysis", too, just to make it clear that in other circumstances I won't be treating current as a vector.
William H. Hayt is also correct for the book he is writing.  In my opinion he is more generally correct, in that he is alluding to the fact that a current vector implies infinite current density.  The interpretation that current is the result of a current vector (your $\vec I = \int_S \vec J \cdot dS$) is probably the most general -- but it's also the hardest one to get your head wrapped around when you're approaching electrodynamics for the first time.
It's good to remember that

*

*No model is complete -- so they all "lie" by omission.

*Some models have known flaws -- so they may just plain lie (i.e., a linearized model of some physical system).

*Any textbook, academic paper, commercial technical report, etc., contains models -- and for the completeness and exact match of those models with reality, see above.

I have a detail-oriented brain and I used to trip over apparent contradictions like this.  I've learned to just understand that in any context, someone has to choose a model to fit their problem and their audience, and there's a very good chance that model isn't going to be exactly the same as someone else's model.
* Never fully accurate results -- we're not gods in that regard.
