본문 바로가기

ios4

tailwind css의 autoprefixer tailwindcss를 사용하면서 backdrop-filter 속성을 사용하는데 Mac의 Safari와 iOS의 브라우저에서 dackdrop-filter 속성이 적용되지 않는것을 보았습니다. https://tailwindcss.com/docs/browser-support#vendor-prefixes Browser Support - Tailwind CSSUnderstanding which browsers Tailwind supports and how to manage vendor prefixes.tailwindcss.com 공식문서에도 이미 https://github.com/postcss/autoprefixer를 설치하라고 안내해주고있었다. GitHub - postcss/autoprefixer: Parse.. 2024. 10. 3.
한꺼번에 모든 모달 닫기 iOS 에서 스토리보드를 사용하여 App 개발중 아래와 같은 상황이 발생하였다. 1. SettingViewController를 Present Modally로 띄움 2. SettingViewController에서 로그아웃 버튼을 누름 3. 로그아웃 절차 진행 후 LoginViewController가 나타남 4. 다시 로그인을 할 경우 모든 모달이 닫히고(이 경우 SettingViewController) RootViewController가 나타남 위와같은 케이스의 해결을 위해 [self performSegueWithIdentifier:@"LoginSegue" sender:self];가 호출된 직후 [self dismissViewControllerAnimated:true completion:nil];를 호출하.. 2015. 1. 22.
네비게이션 바에 환경설정 버튼 올리기 iOS 개발을 하다보면 네비게이션 바에 환경설정 버튼을 넣고 싶은 경우가 있다.네비게이션 바에 올라가는 아이콘의 경우 UIBarButtonItem인데 환경설정 아이콘은 별도로 존재하질 않는다.이미지로 올려도 되겠지만, 톱니바퀴 모양의 폰트가 있으니 이걸 활용하여 올려보도록 하자.아이콘은 위와 같이 생겼다. 네비게이션 바에 올리는 코드는 다음과 같이 간단하다. - (void)viewDidLoad { [super viewDidLoad]; UIBarButtonItem *settingsButton = [[UIBarButtonItem alloc] initWithTitle:@"\u2699" style:UIBarButtonItemStylePlain target:self action:@selector(showSetti.. 2015. 1. 22.
NSString이 null(nil)이거나 비어있는지 체크하기 C#에서 스트링이 null이거나 비어있는지 체크할때는if (String.IsNullorEmpty(s)) { ... }이 코드를 주로 사용하였다. Java의 경우에는 org.apache.commons.leng3.StringUtils를 사용하여if (StringUtils.isEmpty(s)) { ... }이 코드를 주로 사용하였다. 위와 같은 체크를 하고 싶다면 Objective-C 에서는 아래와 같이 하면 된다. if (!s.length) { ... }Objective-C의 경우 s가 nil이더라도 타 언어와는 달리 null point exception이 일어나지 않고nil이나 0가 리턴이 된다. 이와 같은 특성을 활용하여 위와 같이 체크하면 nil이거나 비어있는지를 체크할 수 있다. 2015. 1. 13.