Skip to content

Commit

Permalink
feat: move to px
Browse files Browse the repository at this point in the history
  • Loading branch information
Bibazavr committed May 17, 2024
1 parent 9d266fd commit e31a2b4
Show file tree
Hide file tree
Showing 684 changed files with 23,130 additions and 6,208 deletions.
Binary file added dimensionCompare/new/fold-flip.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added dimensionCompare/new/fold-open.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added dimensionCompare/new/ipad.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added dimensionCompare/new/iphoneSE.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added dimensionCompare/new/medium.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added dimensionCompare/new/small.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added dimensionCompare/was/fold-flip.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added dimensionCompare/was/fold-open.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added dimensionCompare/was/ipad.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added dimensionCompare/was/iphoneSE.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added dimensionCompare/was/medium.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added dimensionCompare/was/small.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
30 changes: 15 additions & 15 deletions ios/MobyDick.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -37,8 +37,8 @@
00E356EE1AD99517003FC87E /* MobyDickTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = MobyDickTests.xctest; sourceTree = BUILT_PRODUCTS_DIR; };
00E356F11AD99517003FC87E /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = "<group>"; };
00E356F21AD99517003FC87E /* MobyDickTests.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = MobyDickTests.m; sourceTree = "<group>"; };
02F15C12586E476E859A462E /* Inter-BoldItalic.ttf */ = {isa = PBXFileReference; explicitFileType = undefined; fileEncoding = undefined; includeInIndex = 0; lastKnownFileType = unknown; name = "Inter-BoldItalic.ttf"; path = "../node_modules/@lad-tech/mobydick-core/src/typography/assets/fonts/Inter-BoldItalic.ttf"; sourceTree = "<group>"; };
0F4B870A4D224592AB180528 /* Inter-Medium.ttf */ = {isa = PBXFileReference; explicitFileType = undefined; fileEncoding = undefined; includeInIndex = 0; lastKnownFileType = unknown; name = "Inter-Medium.ttf"; path = "../node_modules/@lad-tech/mobydick-core/src/typography/assets/fonts/Inter-Medium.ttf"; sourceTree = "<group>"; };
02F15C12586E476E859A462E /* Inter-BoldItalic.ttf */ = {isa = PBXFileReference; explicitFileType = undefined; fileEncoding = 9; includeInIndex = 0; lastKnownFileType = unknown; name = "Inter-BoldItalic.ttf"; path = "../node_modules/@lad-tech/mobydick-core/src/typography/assets/fonts/Inter-BoldItalic.ttf"; sourceTree = "<group>"; };
0F4B870A4D224592AB180528 /* Inter-Medium.ttf */ = {isa = PBXFileReference; explicitFileType = undefined; fileEncoding = 9; includeInIndex = 0; lastKnownFileType = unknown; name = "Inter-Medium.ttf"; path = "../node_modules/@lad-tech/mobydick-core/src/typography/assets/fonts/Inter-Medium.ttf"; sourceTree = "<group>"; };
13B07F961A680F5B00A75B9A /* MobyDick.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = MobyDick.app; sourceTree = BUILT_PRODUCTS_DIR; };
13B07FAF1A68108700A75B9A /* AppDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = AppDelegate.h; path = MobyDick/AppDelegate.h; sourceTree = "<group>"; };
13B07FB01A68108700A75B9A /* AppDelegate.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; name = AppDelegate.mm; path = MobyDick/AppDelegate.mm; sourceTree = "<group>"; };
Expand All @@ -50,14 +50,14 @@
5709B34CF0A7D63546082F79 /* Pods-MobyDick.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-MobyDick.release.xcconfig"; path = "Target Support Files/Pods-MobyDick/Pods-MobyDick.release.xcconfig"; sourceTree = "<group>"; };
5B7EB9410499542E8C5724F5 /* Pods-MobyDick-MobyDickTests.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-MobyDick-MobyDickTests.debug.xcconfig"; path = "Target Support Files/Pods-MobyDick-MobyDickTests/Pods-MobyDick-MobyDickTests.debug.xcconfig"; sourceTree = "<group>"; };
5DCACB8F33CDC322A6C60F78 /* libPods-MobyDick.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-MobyDick.a"; sourceTree = BUILT_PRODUCTS_DIR; };
67B4FAB9822A49BB973439F8 /* Inter-Bold.ttf */ = {isa = PBXFileReference; explicitFileType = undefined; fileEncoding = undefined; includeInIndex = 0; lastKnownFileType = unknown; name = "Inter-Bold.ttf"; path = "../node_modules/@lad-tech/mobydick-core/src/typography/assets/fonts/Inter-Bold.ttf"; sourceTree = "<group>"; };
67B4FAB9822A49BB973439F8 /* Inter-Bold.ttf */ = {isa = PBXFileReference; explicitFileType = undefined; fileEncoding = 9; includeInIndex = 0; lastKnownFileType = unknown; name = "Inter-Bold.ttf"; path = "../node_modules/@lad-tech/mobydick-core/src/typography/assets/fonts/Inter-Bold.ttf"; sourceTree = "<group>"; };
81AB9BB72411601600AC10FF /* LaunchScreen.storyboard */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.storyboard; name = LaunchScreen.storyboard; path = MobyDick/LaunchScreen.storyboard; sourceTree = "<group>"; };
89C6BE57DB24E9ADA2F236DE /* Pods-MobyDick-MobyDickTests.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-MobyDick-MobyDickTests.release.xcconfig"; path = "Target Support Files/Pods-MobyDick-MobyDickTests/Pods-MobyDick-MobyDickTests.release.xcconfig"; sourceTree = "<group>"; };
AC09545204134690B5D0062E /* Inter-Italic.ttf */ = {isa = PBXFileReference; explicitFileType = undefined; fileEncoding = undefined; includeInIndex = 0; lastKnownFileType = unknown; name = "Inter-Italic.ttf"; path = "../node_modules/@lad-tech/mobydick-core/src/typography/assets/fonts/Inter-Italic.ttf"; sourceTree = "<group>"; };
B72366087416423695188D1F /* Neotis.ttf */ = {isa = PBXFileReference; explicitFileType = undefined; fileEncoding = undefined; includeInIndex = 0; lastKnownFileType = unknown; name = Neotis.ttf; path = "../node_modules/@lad-tech/mobydick-core/src/styles/icons/font/assets/fonts/Neotis.ttf"; sourceTree = "<group>"; };
C9208F4754A44ACDB1009C42 /* Inter-Regular.ttf */ = {isa = PBXFileReference; explicitFileType = undefined; fileEncoding = undefined; includeInIndex = 0; lastKnownFileType = unknown; name = "Inter-Regular.ttf"; path = "../node_modules/@lad-tech/mobydick-core/src/typography/assets/fonts/Inter-Regular.ttf"; sourceTree = "<group>"; };
AC09545204134690B5D0062E /* Inter-Italic.ttf */ = {isa = PBXFileReference; explicitFileType = undefined; fileEncoding = 9; includeInIndex = 0; lastKnownFileType = unknown; name = "Inter-Italic.ttf"; path = "../node_modules/@lad-tech/mobydick-core/src/typography/assets/fonts/Inter-Italic.ttf"; sourceTree = "<group>"; };
B72366087416423695188D1F /* Neotis.ttf */ = {isa = PBXFileReference; explicitFileType = undefined; fileEncoding = 9; includeInIndex = 0; lastKnownFileType = unknown; name = Neotis.ttf; path = "../node_modules/@lad-tech/mobydick-core/src/styles/icons/font/assets/fonts/Neotis.ttf"; sourceTree = "<group>"; };
C9208F4754A44ACDB1009C42 /* Inter-Regular.ttf */ = {isa = PBXFileReference; explicitFileType = undefined; fileEncoding = 9; includeInIndex = 0; lastKnownFileType = unknown; name = "Inter-Regular.ttf"; path = "../node_modules/@lad-tech/mobydick-core/src/typography/assets/fonts/Inter-Regular.ttf"; sourceTree = "<group>"; };
ED297162215061F000B7C4FE /* JavaScriptCore.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = JavaScriptCore.framework; path = System/Library/Frameworks/JavaScriptCore.framework; sourceTree = SDKROOT; };
ED3C107DB30644458A97FAC3 /* Inter-SemiBold.ttf */ = {isa = PBXFileReference; explicitFileType = undefined; fileEncoding = undefined; includeInIndex = 0; lastKnownFileType = unknown; name = "Inter-SemiBold.ttf"; path = "../node_modules/@lad-tech/mobydick-core/src/typography/assets/fonts/Inter-SemiBold.ttf"; sourceTree = "<group>"; };
ED3C107DB30644458A97FAC3 /* Inter-SemiBold.ttf */ = {isa = PBXFileReference; explicitFileType = undefined; fileEncoding = 9; includeInIndex = 0; lastKnownFileType = unknown; name = "Inter-SemiBold.ttf"; path = "../node_modules/@lad-tech/mobydick-core/src/typography/assets/fonts/Inter-SemiBold.ttf"; sourceTree = "<group>"; };
/* End PBXFileReference section */

/* Begin PBXFrameworksBuildPhase section */
Expand Down Expand Up @@ -516,8 +516,11 @@
);
PRODUCT_BUNDLE_IDENTIFIER = com.mobydick;
PRODUCT_NAME = MobyDick;
SUPPORTED_PLATFORMS = "iphoneos iphonesimulator";
SUPPORTS_MACCATALYST = NO;
SWIFT_OPTIMIZATION_LEVEL = "-Onone";
SWIFT_VERSION = 5.0;
TARGETED_DEVICE_FAMILY = "1,2";
VERSIONING_SYSTEM = "apple-generic";
};
name = Debug;
Expand All @@ -542,7 +545,10 @@
);
PRODUCT_BUNDLE_IDENTIFIER = com.mobydick;
PRODUCT_NAME = MobyDick;
SUPPORTED_PLATFORMS = "iphoneos iphonesimulator";
SUPPORTS_MACCATALYST = NO;
SWIFT_VERSION = 5.0;
TARGETED_DEVICE_FAMILY = "1,2";
VERSIONING_SYSTEM = "apple-generic";
};
name = Release;
Expand Down Expand Up @@ -617,10 +623,7 @@
"-DFOLLY_USE_LIBCPP=1",
"-DFOLLY_CFG_NO_COROUTINES=1",
);
OTHER_LDFLAGS = (
"$(inherited)",
" ",
);
OTHER_LDFLAGS = "$(inherited) ";
REACT_NATIVE_PATH = "${PODS_ROOT}/../../node_modules/react-native";
SDKROOT = iphoneos;
USE_HERMES = true;
Expand Down Expand Up @@ -692,10 +695,7 @@
"-DFOLLY_USE_LIBCPP=1",
"-DFOLLY_CFG_NO_COROUTINES=1",
);
OTHER_LDFLAGS = (
"$(inherited)",
" ",
);
OTHER_LDFLAGS = "$(inherited) ";
REACT_NATIVE_PATH = "${PODS_ROOT}/../../node_modules/react-native";
SDKROOT = iphoneos;
USE_HERMES = true;
Expand Down
156 changes: 99 additions & 57 deletions ios/MobyDick/Images.xcassets/AppIcon.appiconset/Contents.json
Original file line number Diff line number Diff line change
Expand Up @@ -150,6 +150,66 @@
"scale" : "1x",
"size" : "1024x1024"
},
{
"filename" : "16.png",
"idiom" : "mac",
"scale" : "1x",
"size" : "16x16"
},
{
"filename" : "32.png",
"idiom" : "mac",
"scale" : "2x",
"size" : "16x16"
},
{
"filename" : "32.png",
"idiom" : "mac",
"scale" : "1x",
"size" : "32x32"
},
{
"filename" : "64.png",
"idiom" : "mac",
"scale" : "2x",
"size" : "32x32"
},
{
"filename" : "128.png",
"idiom" : "mac",
"scale" : "1x",
"size" : "128x128"
},
{
"filename" : "256.png",
"idiom" : "mac",
"scale" : "2x",
"size" : "128x128"
},
{
"filename" : "256.png",
"idiom" : "mac",
"scale" : "1x",
"size" : "256x256"
},
{
"filename" : "512.png",
"idiom" : "mac",
"scale" : "2x",
"size" : "256x256"
},
{
"filename" : "512.png",
"idiom" : "mac",
"scale" : "1x",
"size" : "512x512"
},
{
"filename" : "1024.png",
"idiom" : "mac",
"scale" : "2x",
"size" : "512x512"
},
{
"filename" : "48.png",
"idiom" : "watch",
Expand Down Expand Up @@ -180,6 +240,13 @@
"scale" : "3x",
"size" : "29x29"
},
{
"idiom" : "watch",
"role" : "notificationCenter",
"scale" : "2x",
"size" : "33x33",
"subtype" : "45mm"
},
{
"filename" : "80.png",
"idiom" : "watch",
Expand All @@ -196,6 +263,13 @@
"size" : "44x44",
"subtype" : "40mm"
},
{
"idiom" : "watch",
"role" : "appLauncher",
"scale" : "2x",
"size" : "46x46",
"subtype" : "41mm"
},
{
"filename" : "100.png",
"idiom" : "watch",
Expand All @@ -204,6 +278,20 @@
"size" : "50x50",
"subtype" : "44mm"
},
{
"idiom" : "watch",
"role" : "appLauncher",
"scale" : "2x",
"size" : "51x51",
"subtype" : "45mm"
},
{
"idiom" : "watch",
"role" : "appLauncher",
"scale" : "2x",
"size" : "54x54",
"subtype" : "49mm"
},
{
"filename" : "172.png",
"idiom" : "watch",
Expand All @@ -229,70 +317,24 @@
"subtype" : "44mm"
},
{
"filename" : "1024.png",
"idiom" : "watch-marketing",
"scale" : "1x",
"size" : "1024x1024"
},
{
"filename" : "16.png",
"idiom" : "mac",
"scale" : "1x",
"size" : "16x16"
},
{
"filename" : "32.png",
"idiom" : "mac",
"scale" : "2x",
"size" : "16x16"
},
{
"filename" : "32.png",
"idiom" : "mac",
"scale" : "1x",
"size" : "32x32"
},
{
"filename" : "64.png",
"idiom" : "mac",
"scale" : "2x",
"size" : "32x32"
},
{
"filename" : "128.png",
"idiom" : "mac",
"scale" : "1x",
"size" : "128x128"
},
{
"filename" : "256.png",
"idiom" : "mac",
"idiom" : "watch",
"role" : "quickLook",
"scale" : "2x",
"size" : "128x128"
},
{
"filename" : "256.png",
"idiom" : "mac",
"scale" : "1x",
"size" : "256x256"
"size" : "117x117",
"subtype" : "45mm"
},
{
"filename" : "512.png",
"idiom" : "mac",
"idiom" : "watch",
"role" : "quickLook",
"scale" : "2x",
"size" : "256x256"
},
{
"filename" : "512.png",
"idiom" : "mac",
"scale" : "1x",
"size" : "512x512"
"size" : "129x129",
"subtype" : "49mm"
},
{
"filename" : "1024.png",
"idiom" : "mac",
"scale" : "2x",
"size" : "512x512"
"idiom" : "watch-marketing",
"scale" : "1x",
"size" : "1024x1024"
}
],
"info" : {
Expand Down
43 changes: 43 additions & 0 deletions lib/__mocks__/globalMock.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
"use strict";
// RN do Object.freeze for Style in __DEV__
// https://github.com/facebook/react-native/commit/a8e3c7f5780516eb0297830632862484ad032c10#r74968198
// And I don't know why
jest.mock('react-native/Libraries/StyleSheet/StyleSheet.js', () => {
const real = jest.requireActual('react-native/Libraries/StyleSheet/StyleSheet.js');
return {
...real,
create: (obj) => obj,
};
});
// Somehow Platform.isTesting === undefined when running in jest:/
jest.mock('react-native/Libraries/Utilities/Platform', () => {
const real = jest.requireActual('react-native/Libraries/Utilities/Platform');
return {
...real,
isTesting: true,
};
});
// we don't need logs in test's scripts
jest.mock('../scripts/utils/logger'); // or use require
jest.mock('react-native/Libraries/Utilities/BackHandler', () => {
return jest.requireActual('react-native/Libraries/Utilities/__mocks__/BackHandler.js');
});
jest.mock('react-native-safe-area-context', () => {
return jest.requireActual('react-native-safe-area-context/jest/mock').default;
});
jest.mock('react-native/Libraries/Interaction/PanResponder', () => {
const real = jest.requireActual('react-native/Libraries/Interaction/PanResponder');
return {
...real,
create: (config) => ({ panHandlers: config }),
};
});
jest.mock('react-native-calendars', () => {
const real = jest.requireActual('react-native-calendars');
real.Calendar.defaultProps = {
initialDate: '8.01.2022',
};
return {
...real,
};
});
3 changes: 3 additions & 0 deletions lib/__mocks__/svgMock.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
"use strict";
module.exports = 'SvgMock';
module.exports.ReactComponent = 'SvgMock';
9 changes: 9 additions & 0 deletions lib/e2e/const.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.TEXTS = void 0;
exports.TEXTS = {
NAVIGATOR: 'NAVIGATOR',
ADDONS: 'ADDONS',
KNOBS: 'KNOBS',
PREVIEW: 'PREVIEW',
};
47 changes: 47 additions & 0 deletions lib/e2e/core/cta/button.e2e.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
const detox_1 = require("detox");
const const_1 = require("../../const");
const functions_1 = require("../../functions");
const typeTextField = (0, functions_1.getTypeTextField)();
const devicePlatform = (0, functions_1.getPlatform)();
describe('Button', () => {
beforeAll(async () => {
await detox_1.device.launchApp();
});
beforeEach(async () => {
await detox_1.device.reloadReactNative();
});
it('should have basic button', async () => {
await (0, detox_1.element)(detox_1.by.text(const_1.TEXTS.NAVIGATOR)).tap();
await (0, detox_1.element)(detox_1.by.text('basic button')).tap();
await (0, detox_1.element)(detox_1.by.text(const_1.TEXTS.PREVIEW)).tap();
await (0, detox_1.expect)((0, detox_1.element)(detox_1.by.text('text big text'))).toBeVisible();
await (0, detox_1.element)(detox_1.by.text(const_1.TEXTS.ADDONS)).tap();
await (0, detox_1.element)(detox_1.by.text(const_1.TEXTS.KNOBS)).tap();
if (devicePlatform === 'ios') {
await (0, detox_1.element)(detox_1.by.type(typeTextField)).atIndex(4).tap();
await (0, detox_1.element)(detox_1.by.text('large')).tap();
await (0, detox_1.element)(detox_1.by.type(typeTextField)).atIndex(1).tap();
await (0, detox_1.element)(detox_1.by.text('secondary')).tap();
await (0, detox_1.element)(detox_1.by.type(typeTextField)).atIndex(2).clearText();
await (0, detox_1.element)(detox_1.by.type(typeTextField))
.atIndex(2)
.replaceText('Добавить карту');
}
else {
await (0, detox_1.element)(detox_1.by.text('size')).tap({ x: 5, y: 20 });
await (0, detox_1.element)(detox_1.by.text('large')).tap();
await (0, detox_1.element)(detox_1.by.text('type')).tap({ x: 5, y: 20 });
await (0, detox_1.element)(detox_1.by.text('secondary')).tap();
await (0, detox_1.element)(detox_1.by.text('disabled')).tap({ x: 5, y: 30 });
await (0, detox_1.element)(detox_1.by.text('disabled')).tap({ x: 5, y: 30 });
await (0, detox_1.element)(detox_1.by.type(typeTextField)).atIndex(1).clearText();
await (0, detox_1.element)(detox_1.by.type(typeTextField))
.atIndex(1)
.replaceText('Добавить карту');
}
await (0, detox_1.element)(detox_1.by.text(const_1.TEXTS.PREVIEW)).tap();
await (0, detox_1.element)(detox_1.by.text('light')).tap();
});
});
Loading

0 comments on commit e31a2b4

Please sign in to comment.