Skip to content

Commit

Permalink
Merge pull request #348 from Dongshanxu/master
Browse files Browse the repository at this point in the history
9.2.7
  • Loading branch information
shine2008 authored Aug 26, 2022
2 parents 870b414 + 379a741 commit c0dace2
Show file tree
Hide file tree
Showing 303 changed files with 27,043 additions and 25,710 deletions.
6 changes: 5 additions & 1 deletion NEChatUIKit/NEKitChatUI.podspec
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ Pod::Spec.new do |spec|
#

spec.name = "NEKitChatUI"
spec.version = "9.2.6-rc01"
spec.version = "9.2.7"
spec.summary = "Chat Module of IM."

# This description is used to generate tags and improve search results.
Expand All @@ -34,6 +34,10 @@ TODO: Add long description of the pod here.

spec.ios.deployment_target = '9.0'
spec.source_files = 'NEKitChatUI/Classes/**/*'
spec.pod_target_xcconfig = {
'BUILD_LIBRARY_FOR_DISTRIBUTION' => 'YES'
}
spec.user_target_xcconfig = { 'BUILD_LIBRARY_FOR_DISTRIBUTION' => 'YES' }

spec.resource_bundles = {
'NEKitChatUI' => ['NEKitChatUI/Assets/*.png']
Expand Down
10 changes: 4 additions & 6 deletions NEChatUIKit/NEKitChatUI/Assets/en.lproj/Localizable.strings
Original file line number Diff line number Diff line change
@@ -1,10 +1,8 @@
/*
YXLogin.strings
Pods

Created by yu chen on 2021/12/24.

*/
// Copyright (c) 2022 NetEase, Inc. All rights reserved.
// Use of this source code is governed by a MIT license that can be
// found in the LICENSE file.

//MAKR:common
"ok"="ok";
"send_to"="To ";
Expand Down
Original file line number Diff line number Diff line change
@@ -1,10 +1,7 @@
/*
YXLogin.strings
Pods

Created by yu chen on 2021/12/24.
*/
// Copyright (c) 2022 NetEase, Inc. All rights reserved.
// Use of this source code is governed by a MIT license that can be
// found in the LICENSE file.

//MAKR:common
"ok"="确认";
Expand Down
28 changes: 14 additions & 14 deletions NEChatUIKit/NEKitChatUI/Classes/Base/BaseView/ChatBaseCell.swift
Original file line number Diff line number Diff line change
@@ -1,21 +1,21 @@

// Copyright (c) 2022 NetEase, Inc. All rights reserved.
// Use of this source code is governed by a MIT license that can be found in the LICENSE file.
// Copyright (c) 2022 NetEase, Inc. All rights reserved.
// Use of this source code is governed by a MIT license that can be
// found in the LICENSE file.

import UIKit

public class ChatBaseCell: UITableViewCell {
override init(style: UITableViewCell.CellStyle, reuseIdentifier: String?) {
super.init(style: style, reuseIdentifier: reuseIdentifier)
self.selectionStyle = .none
}

required init?(coder: NSCoder) {
fatalError("init(coder:) has not been implemented")
}

public func uploadProgress(_ progress: Float){
fatalError("override in sub class")
}
override init(style: UITableViewCell.CellStyle, reuseIdentifier: String?) {
super.init(style: style, reuseIdentifier: reuseIdentifier)
selectionStyle = .none
}

required init?(coder: NSCoder) {
fatalError("init(coder:) has not been implemented")
}

public func uploadProgress(_ progress: Float) {
fatalError("override in sub class")
}
}
Original file line number Diff line number Diff line change
@@ -1,9 +1,8 @@

// Copyright (c) 2022 NetEase, Inc. All rights reserved.
// Use of this source code is governed by a MIT license that can be found in the LICENSE file.
// Copyright (c) 2022 NetEase, Inc. All rights reserved.
// Use of this source code is governed by a MIT license that can be
// found in the LICENSE file.

import UIKit

class ChatBaseCollectionViewCell: UICollectionViewCell {

}
class ChatBaseCollectionViewCell: UICollectionViewCell {}
Original file line number Diff line number Diff line change
@@ -1,41 +1,40 @@

// Copyright (c) 2022 NetEase, Inc. All rights reserved.
// Use of this source code is governed by a MIT license that can be found in the LICENSE file.
// Copyright (c) 2022 NetEase, Inc. All rights reserved.
// Use of this source code is governed by a MIT license that can be
// found in the LICENSE file.

import UIKit

class ChatCenterTextCell: ChatCornerCell {
public var titleLabel: UILabel = .init()
public var line = UIView()
override init(style: UITableViewCell.CellStyle, reuseIdentifier: String?) {
super.init(style: style, reuseIdentifier: reuseIdentifier)

public var titleLabel: UILabel = UILabel()
public var line = UIView()
override init(style: UITableViewCell.CellStyle, reuseIdentifier: String?) {
super.init(style: style, reuseIdentifier: reuseIdentifier)

self.titleLabel.font = UIFont.systemFont(ofSize: 16)
self.titleLabel.translatesAutoresizingMaskIntoConstraints = false
self.titleLabel.textColor = .ne_redText
self.titleLabel.textAlignment = .center
self.contentView.addSubview(self.titleLabel)
NSLayoutConstraint.activate([
self.titleLabel.leftAnchor.constraint(equalTo: self.contentView.leftAnchor, constant: 36),
self.titleLabel.rightAnchor.constraint(equalTo: self.contentView.rightAnchor, constant: -36),
self.titleLabel.topAnchor.constraint(equalTo: self.contentView.topAnchor),
self.titleLabel.bottomAnchor.constraint(equalTo: self.contentView.bottomAnchor)
])
self.titleLabel.text = "title"
self.line.backgroundColor = .ne_greyLine
self.line.translatesAutoresizingMaskIntoConstraints = false
self.contentView.addSubview(self.line)
NSLayoutConstraint.activate([
self.line.leftAnchor.constraint(equalTo: self.contentView.leftAnchor, constant: 20),
self.line.rightAnchor.constraint(equalTo: self.contentView.rightAnchor, constant: -20),
self.line.heightAnchor.constraint(equalToConstant: 1.0),
self.line.bottomAnchor.constraint(equalTo: self.contentView.bottomAnchor)
])
}

required init?(coder: NSCoder) {
fatalError("init(coder:) has not been implemented")
}

titleLabel.font = UIFont.systemFont(ofSize: 16)
titleLabel.translatesAutoresizingMaskIntoConstraints = false
titleLabel.textColor = .ne_redText
titleLabel.textAlignment = .center
contentView.addSubview(titleLabel)
NSLayoutConstraint.activate([
titleLabel.leftAnchor.constraint(equalTo: contentView.leftAnchor, constant: 36),
titleLabel.rightAnchor.constraint(equalTo: contentView.rightAnchor, constant: -36),
titleLabel.topAnchor.constraint(equalTo: contentView.topAnchor),
titleLabel.bottomAnchor.constraint(equalTo: contentView.bottomAnchor),
])
titleLabel.text = "title"
line.backgroundColor = .ne_greyLine
line.translatesAutoresizingMaskIntoConstraints = false
contentView.addSubview(line)
NSLayoutConstraint.activate([
line.leftAnchor.constraint(equalTo: contentView.leftAnchor, constant: 20),
line.rightAnchor.constraint(equalTo: contentView.rightAnchor, constant: -20),
line.heightAnchor.constraint(equalToConstant: 1.0),
line.bottomAnchor.constraint(equalTo: contentView.bottomAnchor),
])
}

required init?(coder: NSCoder) {
fatalError("init(coder:) has not been implemented")
}
}
Original file line number Diff line number Diff line change
@@ -1,11 +1,10 @@

// Copyright (c) 2022 NetEase, Inc. All rights reserved.
// Use of this source code is governed by a MIT license that can be found in the LICENSE file.
// Copyright (c) 2022 NetEase, Inc. All rights reserved.
// Use of this source code is governed by a MIT license that can be
// found in the LICENSE file.

//this cell has rounding corner style
// this cell has rounding corner style
import UIKit
import NEKitCommonUI

class ChatCornerCell: CornerCell {

}
class ChatCornerCell: CornerCell {}
82 changes: 41 additions & 41 deletions NEChatUIKit/NEKitChatUI/Classes/Base/BaseView/ChatHeaderView.swift
Original file line number Diff line number Diff line change
@@ -1,48 +1,48 @@

// Copyright (c) 2022 NetEase, Inc. All rights reserved.
// Use of this source code is governed by a MIT license that can be found in the LICENSE file.
// Copyright (c) 2022 NetEase, Inc. All rights reserved.
// Use of this source code is governed by a MIT license that can be
// found in the LICENSE file.

import UIKit

public class ChatHeaderView: UIView {

public lazy var titleLabel: UILabel = {
let label = UILabel()
label.font = DefaultTextFont(12)
label.textColor = .ne_greyText
label.translatesAutoresizingMaskIntoConstraints = false
return label
}()

/*
// Only override draw() if you perform custom drawing.
// An empty implementation adversely affects performance during animation.
override func draw(_ rect: CGRect) {
// Drawing code
}
*/

override init(frame: CGRect) {
super.init(frame: frame)
setupUI()
}

required init?(coder: NSCoder) {
super.init(coder: coder)
}

func setupUI(){
clipsToBounds = false
addSubview(titleLabel)
NSLayoutConstraint.activate([
titleLabel.bottomAnchor.constraint(equalTo: self.bottomAnchor, constant: -8),
titleLabel.leftAnchor.constraint(equalTo: self.leftAnchor, constant: 33)
])
backgroundColor = .clear
}

public func setTitle(_ name: String){
titleLabel.text = name.count > 2 ? String(name[name.index(name.endIndex, offsetBy: -2)...]) : name
}
public lazy var titleLabel: UILabel = {
let label = UILabel()
label.font = DefaultTextFont(12)
label.textColor = .ne_greyText
label.translatesAutoresizingMaskIntoConstraints = false
return label
}()

/*
// Only override draw() if you perform custom drawing.
// An empty implementation adversely affects performance during animation.
override func draw(_ rect: CGRect) {
// Drawing code
}
*/

override init(frame: CGRect) {
super.init(frame: frame)
setupUI()
}

required init?(coder: NSCoder) {
super.init(coder: coder)
}

func setupUI() {
clipsToBounds = false
addSubview(titleLabel)
NSLayoutConstraint.activate([
titleLabel.bottomAnchor.constraint(equalTo: bottomAnchor, constant: -8),
titleLabel.leftAnchor.constraint(equalTo: leftAnchor, constant: 33),
])
backgroundColor = .clear
}

public func setTitle(_ name: String) {
titleLabel.text = name
.count > 2 ? String(name[name.index(name.endIndex, offsetBy: -2)...]) : name
}
}
Loading

0 comments on commit c0dace2

Please sign in to comment.