forked from vergnet/application-amicale
Improved search and fixed navigation warning on club about screen
This commit is contained in:
parent
8723765e43
commit
106227fbbb
3 changed files with 7 additions and 5 deletions
|
@ -29,7 +29,6 @@ class ClubListScreen extends React.Component<Props, State> {
|
||||||
|
|
||||||
colors: Object;
|
colors: Object;
|
||||||
|
|
||||||
getRenderItem: Function;
|
|
||||||
categories: Array<Object>;
|
categories: Array<Object>;
|
||||||
|
|
||||||
constructor(props) {
|
constructor(props) {
|
||||||
|
@ -70,7 +69,7 @@ class ClubListScreen extends React.Component<Props, State> {
|
||||||
* @return {*}
|
* @return {*}
|
||||||
*/
|
*/
|
||||||
getHeaderButtons = () => {
|
getHeaderButtons = () => {
|
||||||
const onPress = this.props.navigation.navigate.bind(this, "ClubAboutScreen");
|
const onPress = () => this.props.navigation.navigate( "ClubAboutScreen");
|
||||||
return <HeaderButton icon={'information'} onPress={onPress}/>;
|
return <HeaderButton icon={'information'} onPress={onPress}/>;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -32,8 +32,8 @@ const emailRegex = /^.+@.+\..+$/;
|
||||||
class LoginScreen extends React.Component<Props, State> {
|
class LoginScreen extends React.Component<Props, State> {
|
||||||
|
|
||||||
state = {
|
state = {
|
||||||
email: 'vergnet@etud.insa-toulouse.fr',
|
email: '',
|
||||||
password: '3D514ùdsqg',
|
password: '',
|
||||||
isEmailValidated: false,
|
isEmailValidated: false,
|
||||||
isPasswordValidated: false,
|
isPasswordValidated: false,
|
||||||
loading: false,
|
loading: false,
|
||||||
|
|
|
@ -8,7 +8,10 @@
|
||||||
* @return {string} The sanitized string
|
* @return {string} The sanitized string
|
||||||
*/
|
*/
|
||||||
export function sanitizeString(str: string): string {
|
export function sanitizeString(str: string): string {
|
||||||
return str.toLowerCase().normalize("NFD").replace(/[\u0300-\u036f]/g, "");
|
return str.toLowerCase()
|
||||||
|
.normalize("NFD")
|
||||||
|
.replace(/[\u0300-\u036f]/g, "")
|
||||||
|
.replace(" ", "");
|
||||||
}
|
}
|
||||||
|
|
||||||
export function stringMatchQuery(str: string, query: string) {
|
export function stringMatchQuery(str: string, query: string) {
|
||||||
|
|
Loading…
Reference in a new issue